Practice Real Company Assessment Patterns • Latest 2025–2026 Mock Tests

Programming Exercises

Write a Kotlin program to find the largest of three numbers.

Easy

Problem Statement

Write a Kotlin program to find the largest of three numbers.

Sample Input

Three hardcoded integers, e.g., 3, 7, and 5.

Sample Output

The largest number is: 7

Limits

Time: 2s · Memory: 256 MB

Code Editor
00:00
fun main() { val a = 3 val b = 7 val c = 5 // Add your code here to find the largest number }
Log in or sign up to run or submit your code.Log inSign up
Input
Three hardcoded integers, e.g., 3, 7, and 5.
Expected Output
The largest number is: 7