ミドル
2026年8月19日バグを見つけろ:React / Next.js
コードは1つ。バグを見つけるか、バグがないことを示してください。
tsx
1import { useState } from 'react'
2
3function Stepper() {
4 const [count, setCount] = useState(0)
5
6 const incrementBy3 = () => {
7 setCount(count + 1)
8 setCount(count + 1)
9 setCount(count + 1)
10 }
11
12 return (
13 <div>
14 <p>Count: {count}</p>
15 <button onClick={incrementBy3}>+3</button>
16 </div>
17 )
18}問題のある行をクリックしてください。
あなたの判断
1日1回まで。回答するとすぐに正解が表示されます。
連続記録を守る
アカウントを作成すると連続記録を保存し、進捗を追跡できます。