JavaScript Basics - Variables and Functions

Official
JavaScriptBeginner
Overview

Practice basic variable declarations and function definitions in JavaScript.

Rules
Mode
All LinesNormalOff
Time Limit
1:00
Mistake Limit
Unlimited
Code PreviewJavaScript
const greeting = "Hello, World!";
const user = { name: "Alice", age: 25 };

function calculateSum(a, b) {
  return a + b;
}

const result = calculateSum(10, 20);
console.log(`Result: ${result}`);
Statistics
Mode
All LinesNormalOff
Time Limit
1:00
Mistake Limit
Unlimited
Created
January 20, 2026
Challengers
4
Total Attempts
15
Completions
0
Avg WPM
38.45
Avg Accuracy
93.85%
Ranking
RankUserWPMAccuracy
50.9496.5%
45.0496.5%
4594.0%

Exercise Ranking

Top typers for this exercise

Total Participants

4

Period

All Time

Total Challenges (All Users)

15

Total Practice Time (All Users)

00:12:08

Total Keystrokes (All Users)

2,449

Period
Sort
RankUserwpmAccuracyStarted/CompletedCorrect/StrokesTotal TimeLast Attempt
50.9496.50%3/2386/39500:01:382/10/2026, 12:45 PM
45.0496.50%8/31,156/1,24900:06:412/2/2026, 05:19 AM
45.0094.00%3/2573/60400:02:481/21/2026, 01:37 PM
4
38.0095.00%1/0191/20100:01:001/25/2026, 01:40 PM
Ranking of 4 users