Ways to climb 12 stairs (1 or 2 steps).
Toolliyo Coach
Progressive help: Nudge → Guide → Approach. Full solution stays behind the Solution tab.
Editor is open — no login wall to practice.
| Test | Status | Details |
|---|
Ready — edit the code above and click Run or Submit.
using System;
using System.Collections.Generic;
using System.Linq;
class Program
{
static void Main()
{
int n = 12;
int a = 1, b = 1;
for (int k = 2; k <= n; k++) { int t = a + b; a = b; b = t; }
Console.WriteLine(b);
}
}
Prefer Coach (Nudge → Guide → Approach) before revealing. No forced signup.
Same as Fibonacci — classic DP intro.
Sign in to save and review your submission history. You can still Run code on the Editor tab as a guest.
Sign in