CODEBHAVYA โ€ข PYTHON PRACTICE ARENA

โœ๏ธ Python Practice Arena

Move from Python foundations to placement-level problem solving through 12 progressive levels. Every challenge uses the CodeBhavya story format, a complete problem contract and the appropriate browser or local practice mode.

12Progressive Levels
240Total Challenges
220Online Judge Challenges
20Local File Labs
Online Judge Progress0%
0 / 220Solved
0Completed with Solution
0 / 22000Online Judge Score
100Points per Challenge
CHOOSE YOUR PATH

๐ŸŽฏ Choose Your Practice Level

Start with Level 1 and move step by step, or jump directly to the Python topic you want to practise.

Beginner Practice

Build confidence with syntax, output and the basic Python workflow.

Intermediate Practice

Strengthen loops, text and collection-based problem solving.

Advanced Practice

Apply modular design, files and object-oriented thinking.

Placement Practice

Finish with interview-style Python coding challenges.

STORY-BASED CHALLENGES

๐Ÿงฉ Open a Level & Start Solving

Each level contains 20 compact challenge cards. Open a challenge to see its story, task, input/output contract, constraints, examples, concepts and practice workspace.

๐Ÿš€Level 1 โ€” Python FoundationsSyntax, comments, output and small beginner programs. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Welcome Message

Core Skill: print() and String Literals

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Welcome Message

Orientation Desk needs a reliable Python utility. Display the required welcome message exactly as shown.

๐ŸŽฏ Your Task

Display the required welcome message exactly as shown.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Do not add quotation marks or extra spaces to the output.

Example Input
No input
Example Output
Hello Python
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsprint()StringsEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Learner Profile Card

Core Skill: input() and Labelled Output

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Learner Profile Card

Campus Portal needs a reliable Python utility. Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐ŸŽฏ Your Task

Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each input value is a non-empty line of at most 40 characters.

Example Input
Asha
Python
Placement
Example Output
Name: Asha
Course: Python
Goal: Placement
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsinput() and Labelled OutputEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Sum and Product Board

Core Skill: Variables and Arithmetic

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Sum and Product Board

Learning Studio needs a reliable Python utility. Read two integers and display their sum and product on labelled lines.

๐ŸŽฏ Your Task

Read two integers and display their sum and product on labelled lines.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10000 โ‰ค each integer โ‰ค 10000.

Example Input
5
7
Example Output
Sum = 12
Product = 35
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsVariables and ArithmeticEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Three-Line Learning Flow

Core Skill: Newlines and Multiple Output Lines

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Three-Line Learning Flow

Skill Tracker needs a reliable Python utility. Display the three required learning actions, one action per line.

๐ŸŽฏ Your Task

Display the three required learning actions, one action per line.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Preserve the order and capitalisation shown.

Example Input
No input
Example Output
Learn
Practice
Build
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsNewlines and Multiple Output LinesEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Value Swap

Core Skill: Assignment and Temporary Variables

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Value Swap

Mentor Console needs a reliable Python utility. Read two words and print them in swapped order on one line.

๐ŸŽฏ Your Task

Read two words and print them in swapped order on one line.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each value is one word without spaces.

Example Input
red
blue
Example Output
blue red
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsAssignment and Temporary VariablesEasy100 Points
CHALLENGE 06 Easy

Library Counter โ€” Welcome Message

Core Skill: print() and String Literals

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Welcome Message

Library Counter needs a reliable Python utility. Display the required welcome message exactly as shown.

๐ŸŽฏ Your Task

Display the required welcome message exactly as shown.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Do not add quotation marks or extra spaces to the output.

Example Input
No input
Example Output
CodeBhavya
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsprint()StringsEasy100 Points
CHALLENGE 07 Easy

Practice Lab โ€” Learner Profile Card

Core Skill: input() and Labelled Output

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Learner Profile Card

Practice Lab needs a reliable Python utility. Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐ŸŽฏ Your Task

Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each input value is a non-empty line of at most 40 characters.

Example Input
Ravi
Python
Projects
Example Output
Name: Ravi
Course: Python
Goal: Projects
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsinput() and Labelled OutputEasy100 Points
CHALLENGE 08 Easy

Quiz Engine โ€” Sum and Product Board

Core Skill: Variables and Arithmetic

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Sum and Product Board

Quiz Engine needs a reliable Python utility. Read two integers and display their sum and product on labelled lines.

๐ŸŽฏ Your Task

Read two integers and display their sum and product on labelled lines.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10000 โ‰ค each integer โ‰ค 10000.

Example Input
8
4
Example Output
Sum = 12
Product = 32
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsVariables and ArithmeticEasy100 Points
CHALLENGE 09 Easy

Project Hub โ€” Three-Line Learning Flow

Core Skill: Newlines and Multiple Output Lines

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Three-Line Learning Flow

Project Hub needs a reliable Python utility. Display the three required learning actions, one action per line.

๐ŸŽฏ Your Task

Display the three required learning actions, one action per line.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Preserve the order and capitalisation shown.

Example Input
No input
Example Output
Think
Code
Test
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsNewlines and Multiple Output LinesEasy100 Points
CHALLENGE 10 Easy

Placement Desk โ€” Value Swap

Core Skill: Assignment and Temporary Variables

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Value Swap

Placement Desk needs a reliable Python utility. Read two words and print them in swapped order on one line.

๐ŸŽฏ Your Task

Read two words and print them in swapped order on one line.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each value is one word without spaces.

Example Input
left
right
Example Output
right left
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsAssignment and Temporary VariablesEasy100 Points
CHALLENGE 11 Easy

Team Dashboard โ€” Welcome Message

Core Skill: print() and String Literals

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Welcome Message

Team Dashboard needs a reliable Python utility. Display the required welcome message exactly as shown.

๐ŸŽฏ Your Task

Display the required welcome message exactly as shown.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Do not add quotation marks or extra spaces to the output.

Example Input
No input
Example Output
Learn Practice Build
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsprint()StringsEasy100 Points
CHALLENGE 12 Easy

Data Centre โ€” Learner Profile Card

Core Skill: input() and Labelled Output

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Learner Profile Card

Data Centre needs a reliable Python utility. Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐ŸŽฏ Your Task

Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each input value is a non-empty line of at most 40 characters.

Example Input
Meera
Python
Interview
Example Output
Name: Meera
Course: Python
Goal: Interview
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsinput() and Labelled OutputEasy100 Points
CHALLENGE 13 Medium

Student Vault โ€” Sum and Product Board

Core Skill: Variables and Arithmetic

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Sum and Product Board

Student Vault needs a reliable Python utility. Read two integers and display their sum and product on labelled lines.

๐ŸŽฏ Your Task

Read two integers and display their sum and product on labelled lines.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10000 โ‰ค each integer โ‰ค 10000.

Example Input
12
3
Example Output
Sum = 15
Product = 36
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsVariables and ArithmeticMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Three-Line Learning Flow

Core Skill: Newlines and Multiple Output Lines

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Three-Line Learning Flow

Workshop Board needs a reliable Python utility. Display the three required learning actions, one action per line.

๐ŸŽฏ Your Task

Display the three required learning actions, one action per line.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Preserve the order and capitalisation shown.

Example Input
No input
Example Output
Read
Trace
Run
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsNewlines and Multiple Output LinesMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Value Swap

Core Skill: Assignment and Temporary Variables

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Value Swap

Career Console needs a reliable Python utility. Read two words and print them in swapped order on one line.

๐ŸŽฏ Your Task

Read two words and print them in swapped order on one line.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each value is one word without spaces.

Example Input
first
second
Example Output
second first
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsAssignment and Temporary VariablesMedium100 Points
CHALLENGE 16 Medium

Research Desk โ€” Welcome Message

Core Skill: print() and String Literals

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Welcome Message

Research Desk needs a reliable Python utility. Display the required welcome message exactly as shown.

๐ŸŽฏ Your Task

Display the required welcome message exactly as shown.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Do not add quotation marks or extra spaces to the output.

Example Input
No input
Example Output
Python Ready
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsprint()StringsMedium100 Points
CHALLENGE 17 Medium

Challenge Arena โ€” Learner Profile Card

Core Skill: input() and Labelled Output

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Learner Profile Card

Challenge Arena needs a reliable Python utility. Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐ŸŽฏ Your Task

Read a learner name, course and goal on separate lines, then display a labelled three-line profile.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each input value is a non-empty line of at most 40 characters.

Example Input
Kiran
Python
Automation
Example Output
Name: Kiran
Course: Python
Goal: Automation
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python Basicsinput() and Labelled OutputMedium100 Points
CHALLENGE 18 Medium

Revision Room โ€” Sum and Product Board

Core Skill: Variables and Arithmetic

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Sum and Product Board

Revision Room needs a reliable Python utility. Read two integers and display their sum and product on labelled lines.

๐ŸŽฏ Your Task

Read two integers and display their sum and product on labelled lines.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10000 โ‰ค each integer โ‰ค 10000.

Example Input
9
11
Example Output
Sum = 20
Product = 99
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsVariables and ArithmeticMedium100 Points
CHALLENGE 19 Medium

Interview Lab โ€” Three-Line Learning Flow

Core Skill: Newlines and Multiple Output Lines

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Three-Line Learning Flow

Interview Lab needs a reliable Python utility. Display the three required learning actions, one action per line.

๐ŸŽฏ Your Task

Display the three required learning actions, one action per line.

๐Ÿ“ฅ Input Format

No runtime input is required.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Preserve the order and capitalisation shown.

Example Input
No input
Example Output
Plan
Build
Grow
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsNewlines and Multiple Output LinesMedium100 Points
CHALLENGE 20 Medium

CodeBhavya Hub โ€” Value Swap

Core Skill: Assignment and Temporary Variables

Python BasicsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Value Swap

CodeBhavya Hub needs a reliable Python utility. Read two words and print them in swapped order on one line.

๐ŸŽฏ Your Task

Read two words and print them in swapped order on one line.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each value is one word without spaces.

Example Input
learn
build
Example Output
build learn
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Python BasicsAssignment and Temporary VariablesMedium100 Points
๐Ÿ“ฆLevel 2 โ€” Data Types & I/OVariables, conversion, formatted input and output. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Marks Summary

Core Skill: Integer Conversion and Average

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Marks Summary

Orientation Desk needs a reliable Python utility. Read three integer marks, then display their total and average rounded to two decimal places.

๐ŸŽฏ Your Task

Read three integer marks, then display their total and average rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค every mark โ‰ค 100.

Example Input
75
82
91
Example Output
Total = 248
Average = 82.67
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OInteger Conversion and AverageEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Temperature Converter

Core Skill: Floating-Point Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Temperature Converter

Campus Portal needs a reliable Python utility. Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐ŸŽฏ Your Task

Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-273.15 โ‰ค Celsius โ‰ค 10000.

Example Input
25
Example Output
Fahrenheit = 77.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFloating-Point ConversionEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Distance Converter

Core Skill: Numeric Types and Units

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Distance Converter

Learning Studio needs a reliable Python utility. Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐ŸŽฏ Your Task

Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค distance โ‰ค 100000.

Example Input
2.5
Example Output
Metres = 2500.00
Centimetres = 250000.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/ONumeric Types and UnitsEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Discount Bill

Core Skill: Formatted Financial Output

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Discount Bill

Skill Tracker needs a reliable Python utility. Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐ŸŽฏ Your Task

Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Quantity is positive; price and discount are non-negative; discount โ‰ค 100.

Example Input
5
100
10
Example Output
Final Bill = 450.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFormatted Financial OutputEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Formatted Student Record

Core Skill: f-Strings and Type Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Formatted Student Record

Mentor Console needs a reliable Python utility. Read a name, age and score, then print one precisely formatted student record.

๐ŸŽฏ Your Task

Read a name, age and score, then print one precisely formatted student record.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one non-empty line; 1 โ‰ค age โ‰ค 120; 0 โ‰ค score โ‰ค 100.

Example Input
Asha
19
91.5
Example Output
Name: Asha | Age: 19 | Score: 91.50
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/Of-Strings and Type ConversionEasy100 Points
CHALLENGE 06 Easy

Library Counter โ€” Marks Summary

Core Skill: Integer Conversion and Average

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Marks Summary

Library Counter needs a reliable Python utility. Read three integer marks, then display their total and average rounded to two decimal places.

๐ŸŽฏ Your Task

Read three integer marks, then display their total and average rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค every mark โ‰ค 100.

Example Input
60
70
80
Example Output
Total = 210
Average = 70.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OInteger Conversion and AverageEasy100 Points
CHALLENGE 07 Easy

Practice Lab โ€” Temperature Converter

Core Skill: Floating-Point Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Temperature Converter

Practice Lab needs a reliable Python utility. Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐ŸŽฏ Your Task

Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-273.15 โ‰ค Celsius โ‰ค 10000.

Example Input
0
Example Output
Fahrenheit = 32.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFloating-Point ConversionEasy100 Points
CHALLENGE 08 Easy

Quiz Engine โ€” Distance Converter

Core Skill: Numeric Types and Units

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Distance Converter

Quiz Engine needs a reliable Python utility. Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐ŸŽฏ Your Task

Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค distance โ‰ค 100000.

Example Input
1.2
Example Output
Metres = 1200.00
Centimetres = 120000.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/ONumeric Types and UnitsEasy100 Points
CHALLENGE 09 Easy

Project Hub โ€” Discount Bill

Core Skill: Formatted Financial Output

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Discount Bill

Project Hub needs a reliable Python utility. Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐ŸŽฏ Your Task

Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Quantity is positive; price and discount are non-negative; discount โ‰ค 100.

Example Input
3
249.5
5
Example Output
Final Bill = 711.07
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFormatted Financial OutputEasy100 Points
CHALLENGE 10 Easy

Placement Desk โ€” Formatted Student Record

Core Skill: f-Strings and Type Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Formatted Student Record

Placement Desk needs a reliable Python utility. Read a name, age and score, then print one precisely formatted student record.

๐ŸŽฏ Your Task

Read a name, age and score, then print one precisely formatted student record.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one non-empty line; 1 โ‰ค age โ‰ค 120; 0 โ‰ค score โ‰ค 100.

Example Input
Ravi
21
84
Example Output
Name: Ravi | Age: 21 | Score: 84.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/Of-Strings and Type ConversionEasy100 Points
CHALLENGE 11 Easy

Team Dashboard โ€” Marks Summary

Core Skill: Integer Conversion and Average

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Marks Summary

Team Dashboard needs a reliable Python utility. Read three integer marks, then display their total and average rounded to two decimal places.

๐ŸŽฏ Your Task

Read three integer marks, then display their total and average rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค every mark โ‰ค 100.

Example Input
88
92
96
Example Output
Total = 276
Average = 92.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OInteger Conversion and AverageEasy100 Points
CHALLENGE 12 Easy

Data Centre โ€” Temperature Converter

Core Skill: Floating-Point Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Temperature Converter

Data Centre needs a reliable Python utility. Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐ŸŽฏ Your Task

Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-273.15 โ‰ค Celsius โ‰ค 10000.

Example Input
37.5
Example Output
Fahrenheit = 99.50
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFloating-Point ConversionEasy100 Points
CHALLENGE 13 Medium

Student Vault โ€” Distance Converter

Core Skill: Numeric Types and Units

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Distance Converter

Student Vault needs a reliable Python utility. Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐ŸŽฏ Your Task

Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค distance โ‰ค 100000.

Example Input
7
Example Output
Metres = 7000.00
Centimetres = 700000.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/ONumeric Types and UnitsMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Discount Bill

Core Skill: Formatted Financial Output

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Discount Bill

Workshop Board needs a reliable Python utility. Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐ŸŽฏ Your Task

Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Quantity is positive; price and discount are non-negative; discount โ‰ค 100.

Example Input
8
75
12.5
Example Output
Final Bill = 525.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFormatted Financial OutputMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Formatted Student Record

Core Skill: f-Strings and Type Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Formatted Student Record

Career Console needs a reliable Python utility. Read a name, age and score, then print one precisely formatted student record.

๐ŸŽฏ Your Task

Read a name, age and score, then print one precisely formatted student record.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one non-empty line; 1 โ‰ค age โ‰ค 120; 0 โ‰ค score โ‰ค 100.

Example Input
Meera
20
96.25
Example Output
Name: Meera | Age: 20 | Score: 96.25
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/Of-Strings and Type ConversionMedium100 Points
CHALLENGE 16 Medium

Research Desk โ€” Marks Summary

Core Skill: Integer Conversion and Average

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Marks Summary

Research Desk needs a reliable Python utility. Read three integer marks, then display their total and average rounded to two decimal places.

๐ŸŽฏ Your Task

Read three integer marks, then display their total and average rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค every mark โ‰ค 100.

Example Input
45
67
89
Example Output
Total = 201
Average = 67.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OInteger Conversion and AverageMedium100 Points
CHALLENGE 17 Medium

Challenge Arena โ€” Temperature Converter

Core Skill: Floating-Point Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Temperature Converter

Challenge Arena needs a reliable Python utility. Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐ŸŽฏ Your Task

Read a Celsius temperature and display its Fahrenheit value rounded to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-273.15 โ‰ค Celsius โ‰ค 10000.

Example Input
-10
Example Output
Fahrenheit = 14.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFloating-Point ConversionMedium100 Points
CHALLENGE 18 Medium

Revision Room โ€” Distance Converter

Core Skill: Numeric Types and Units

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Distance Converter

Revision Room needs a reliable Python utility. Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐ŸŽฏ Your Task

Read a distance in kilometres and display metres and centimetres, both to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค distance โ‰ค 100000.

Example Input
0.75
Example Output
Metres = 750.00
Centimetres = 75000.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/ONumeric Types and UnitsMedium100 Points
CHALLENGE 19 Medium

Interview Lab โ€” Discount Bill

Core Skill: Formatted Financial Output

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Discount Bill

Interview Lab needs a reliable Python utility. Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐ŸŽฏ Your Task

Read quantity, unit price and discount percentage, then print the final bill to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Quantity is positive; price and discount are non-negative; discount โ‰ค 100.

Example Input
2
999
20
Example Output
Final Bill = 1598.40
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/OFormatted Financial OutputMedium100 Points
CHALLENGE 20 Medium

CodeBhavya Hub โ€” Formatted Student Record

Core Skill: f-Strings and Type Conversion

Data & I/OOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Formatted Student Record

CodeBhavya Hub needs a reliable Python utility. Read a name, age and score, then print one precisely formatted student record.

๐ŸŽฏ Your Task

Read a name, age and score, then print one precisely formatted student record.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one non-empty line; 1 โ‰ค age โ‰ค 120; 0 โ‰ค score โ‰ค 100.

Example Input
Kiran
22
78.75
Example Output
Name: Kiran | Age: 22 | Score: 78.75
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Data & I/Of-Strings and Type ConversionMedium100 Points
โž—Level 3 โ€” Operators & ExpressionsArithmetic, precedence, comparison, logic and bitwise work. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Precedence Calculator

Core Skill: Operator Precedence

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Precedence Calculator

Orientation Desk needs a reliable Python utility. Read a, b and c, then evaluate a + b * c using Python precedence.

๐ŸŽฏ Your Task

Read a, b and c, then evaluate a + b * c using Python precedence.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค a, b, c โ‰ค 1000.

Example Input
4
7
3
Example Output
Result = 25
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsOperator PrecedenceEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Division Report

Core Skill: Floor Division and Modulus

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Division Report

Campus Portal needs a reliable Python utility. Read a positive dividend and divisor, then display quotient and remainder.

๐ŸŽฏ Your Task

Read a positive dividend and divisor, then display quotient and remainder.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค divisor โ‰ค dividend โ‰ค 1000000.

Example Input
29
5
Example Output
Quotient = 5
Remainder = 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsFloor Division and ModulusEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Three-Digit Extractor

Core Skill: Integer Division and Remainder

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Three-Digit Extractor

Learning Studio needs a reliable Python utility. Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐ŸŽฏ Your Task

Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

100 โ‰ค number โ‰ค 999.

Example Input
472
Example Output
Digits = 4 7 2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsInteger Division and RemainderEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Range Membership Test

Core Skill: Comparison and Logical Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Range Membership Test

Skill Tracker needs a reliable Python utility. Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐ŸŽฏ Your Task

Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-100000 โ‰ค number โ‰ค 100000.

Example Input
27
Example Output
True
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsComparison and Logical OperatorsEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Bitwise Console

Core Skill: Bitwise Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Bitwise Console

Mentor Console needs a reliable Python utility. Read two non-negative integers and display their bitwise AND, OR and XOR.

๐ŸŽฏ Your Task

Read two non-negative integers and display their bitwise AND, OR and XOR.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค each integer โ‰ค 1000000.

Example Input
6
3
Example Output
AND = 2
OR = 7
XOR = 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsBitwise OperatorsEasy100 Points
CHALLENGE 06 Easy

Library Counter โ€” Precedence Calculator

Core Skill: Operator Precedence

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Precedence Calculator

Library Counter needs a reliable Python utility. Read a, b and c, then evaluate a + b * c using Python precedence.

๐ŸŽฏ Your Task

Read a, b and c, then evaluate a + b * c using Python precedence.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค a, b, c โ‰ค 1000.

Example Input
8
2
5
Example Output
Result = 18
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsOperator PrecedenceEasy100 Points
CHALLENGE 07 Easy

Practice Lab โ€” Division Report

Core Skill: Floor Division and Modulus

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Division Report

Practice Lab needs a reliable Python utility. Read a positive dividend and divisor, then display quotient and remainder.

๐ŸŽฏ Your Task

Read a positive dividend and divisor, then display quotient and remainder.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค divisor โ‰ค dividend โ‰ค 1000000.

Example Input
100
9
Example Output
Quotient = 11
Remainder = 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsFloor Division and ModulusEasy100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Three-Digit Extractor

Core Skill: Integer Division and Remainder

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Three-Digit Extractor

Quiz Engine needs a reliable Python utility. Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐ŸŽฏ Your Task

Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

100 โ‰ค number โ‰ค 999.

Example Input
905
Example Output
Digits = 9 0 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsInteger Division and RemainderMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Range Membership Test

Core Skill: Comparison and Logical Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Range Membership Test

Project Hub needs a reliable Python utility. Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐ŸŽฏ Your Task

Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-100000 โ‰ค number โ‰ค 100000.

Example Input
45
Example Output
False
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsComparison and Logical OperatorsMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Bitwise Console

Core Skill: Bitwise Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Bitwise Console

Placement Desk needs a reliable Python utility. Read two non-negative integers and display their bitwise AND, OR and XOR.

๐ŸŽฏ Your Task

Read two non-negative integers and display their bitwise AND, OR and XOR.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค each integer โ‰ค 1000000.

Example Input
12
5
Example Output
AND = 4
OR = 13
XOR = 9
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsBitwise OperatorsMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Precedence Calculator

Core Skill: Operator Precedence

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Precedence Calculator

Team Dashboard needs a reliable Python utility. Read a, b and c, then evaluate a + b * c using Python precedence.

๐ŸŽฏ Your Task

Read a, b and c, then evaluate a + b * c using Python precedence.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค a, b, c โ‰ค 1000.

Example Input
10
6
2
Example Output
Result = 22
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsOperator PrecedenceMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Division Report

Core Skill: Floor Division and Modulus

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Division Report

Data Centre needs a reliable Python utility. Read a positive dividend and divisor, then display quotient and remainder.

๐ŸŽฏ Your Task

Read a positive dividend and divisor, then display quotient and remainder.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค divisor โ‰ค dividend โ‰ค 1000000.

Example Input
47
6
Example Output
Quotient = 7
Remainder = 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsFloor Division and ModulusMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Three-Digit Extractor

Core Skill: Integer Division and Remainder

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Three-Digit Extractor

Student Vault needs a reliable Python utility. Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐ŸŽฏ Your Task

Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

100 โ‰ค number โ‰ค 999.

Example Input
381
Example Output
Digits = 3 8 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsInteger Division and RemainderMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Range Membership Test

Core Skill: Comparison and Logical Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Range Membership Test

Workshop Board needs a reliable Python utility. Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐ŸŽฏ Your Task

Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-100000 โ‰ค number โ‰ค 100000.

Example Input
11
Example Output
True
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsComparison and Logical OperatorsMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Bitwise Console

Core Skill: Bitwise Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Bitwise Console

Career Console needs a reliable Python utility. Read two non-negative integers and display their bitwise AND, OR and XOR.

๐ŸŽฏ Your Task

Read two non-negative integers and display their bitwise AND, OR and XOR.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค each integer โ‰ค 1000000.

Example Input
9
10
Example Output
AND = 8
OR = 11
XOR = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsBitwise OperatorsMedium100 Points
CHALLENGE 16 Medium

Research Desk โ€” Precedence Calculator

Core Skill: Operator Precedence

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Precedence Calculator

Research Desk needs a reliable Python utility. Read a, b and c, then evaluate a + b * c using Python precedence.

๐ŸŽฏ Your Task

Read a, b and c, then evaluate a + b * c using Python precedence.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค a, b, c โ‰ค 1000.

Example Input
3
9
4
Example Output
Result = 39
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsOperator PrecedenceMedium100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Division Report

Core Skill: Floor Division and Modulus

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Division Report

Challenge Arena needs a reliable Python utility. Read a positive dividend and divisor, then display quotient and remainder.

๐ŸŽฏ Your Task

Read a positive dividend and divisor, then display quotient and remainder.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค divisor โ‰ค dividend โ‰ค 1000000.

Example Input
88
7
Example Output
Quotient = 12
Remainder = 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsFloor Division and ModulusHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Three-Digit Extractor

Core Skill: Integer Division and Remainder

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Three-Digit Extractor

Revision Room needs a reliable Python utility. Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐ŸŽฏ Your Task

Read a three-digit positive integer and display its hundreds, tens and ones digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

100 โ‰ค number โ‰ค 999.

Example Input
764
Example Output
Digits = 7 6 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsInteger Division and RemainderHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Range Membership Test

Core Skill: Comparison and Logical Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Range Membership Test

Interview Lab needs a reliable Python utility. Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐ŸŽฏ Your Task

Print True only when the integer lies from 10 through 50 inclusive and is not divisible by 5.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-100000 โ‰ค number โ‰ค 100000.

Example Input
52
Example Output
False
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsComparison and Logical OperatorsHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Bitwise Console

Core Skill: Bitwise Operators

OperatorsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Bitwise Console

CodeBhavya Hub needs a reliable Python utility. Read two non-negative integers and display their bitwise AND, OR and XOR.

๐ŸŽฏ Your Task

Read two non-negative integers and display their bitwise AND, OR and XOR.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค each integer โ‰ค 1000000.

Example Input
15
7
Example Output
AND = 7
OR = 15
XOR = 8
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OperatorsBitwise OperatorsHard100 Points
๐Ÿ”€Level 4 โ€” Decision MakingConditions, chained decisions and boundary handling. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Number Classifier

Core Skill: if / elif / else

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Number Classifier

Orientation Desk needs a reliable Python utility. Read an integer and classify it as Positive, Negative or Zero.

๐ŸŽฏ Your Task

Read an integer and classify it as Positive, Negative or Zero.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10^9 โ‰ค number โ‰ค 10^9.

Example Input
18
Example Output
Positive
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Decisionsif / elif / elseEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Largest of Three

Core Skill: Chained Comparisons

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Largest of Three

Campus Portal needs a reliable Python utility. Read three integers and display the largest value.

๐ŸŽฏ Your Task

Read three integers and display the largest value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Values may be equal and may be negative.

Example Input
5
12
9
Example Output
Largest = 12
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsChained ComparisonsEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Grade Boundary

Core Skill: Ordered elif Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Grade Boundary

Learning Studio needs a reliable Python utility. Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐ŸŽฏ Your Task

Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค mark โ‰ค 100.

Example Input
94
Example Output
Grade = A
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsOrdered elif ConditionsEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Leap Year Validator

Core Skill: Nested Logical Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Leap Year Validator

Skill Tracker needs a reliable Python utility. Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐ŸŽฏ Your Task

Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค year โ‰ค 9999.

Example Input
2024
Example Output
Leap Year
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsNested Logical ConditionsEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Triangle Inspector

Core Skill: Compound Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Triangle Inspector

Mentor Console needs a reliable Python utility. Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐ŸŽฏ Your Task

Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค each side โ‰ค 100000.

Example Input
5
5
5
Example Output
Equilateral
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsCompound ConditionsEasy100 Points
CHALLENGE 06 Easy

Library Counter โ€” Number Classifier

Core Skill: if / elif / else

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Number Classifier

Library Counter needs a reliable Python utility. Read an integer and classify it as Positive, Negative or Zero.

๐ŸŽฏ Your Task

Read an integer and classify it as Positive, Negative or Zero.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10^9 โ‰ค number โ‰ค 10^9.

Example Input
-7
Example Output
Negative
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Decisionsif / elif / elseEasy100 Points
CHALLENGE 07 Easy

Practice Lab โ€” Largest of Three

Core Skill: Chained Comparisons

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Largest of Three

Practice Lab needs a reliable Python utility. Read three integers and display the largest value.

๐ŸŽฏ Your Task

Read three integers and display the largest value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Values may be equal and may be negative.

Example Input
40
7
18
Example Output
Largest = 40
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsChained ComparisonsEasy100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Grade Boundary

Core Skill: Ordered elif Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Grade Boundary

Quiz Engine needs a reliable Python utility. Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐ŸŽฏ Your Task

Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค mark โ‰ค 100.

Example Input
82
Example Output
Grade = B
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsOrdered elif ConditionsMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Leap Year Validator

Core Skill: Nested Logical Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Leap Year Validator

Project Hub needs a reliable Python utility. Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐ŸŽฏ Your Task

Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค year โ‰ค 9999.

Example Input
1900
Example Output
Not Leap Year
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsNested Logical ConditionsMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Triangle Inspector

Core Skill: Compound Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Triangle Inspector

Placement Desk needs a reliable Python utility. Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐ŸŽฏ Your Task

Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค each side โ‰ค 100000.

Example Input
5
5
8
Example Output
Isosceles
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsCompound ConditionsMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Number Classifier

Core Skill: if / elif / else

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Number Classifier

Team Dashboard needs a reliable Python utility. Read an integer and classify it as Positive, Negative or Zero.

๐ŸŽฏ Your Task

Read an integer and classify it as Positive, Negative or Zero.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10^9 โ‰ค number โ‰ค 10^9.

Example Input
0
Example Output
Zero
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Decisionsif / elif / elseMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Largest of Three

Core Skill: Chained Comparisons

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Largest of Three

Data Centre needs a reliable Python utility. Read three integers and display the largest value.

๐ŸŽฏ Your Task

Read three integers and display the largest value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Values may be equal and may be negative.

Example Input
-3
-8
-1
Example Output
Largest = -1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsChained ComparisonsMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Grade Boundary

Core Skill: Ordered elif Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Grade Boundary

Student Vault needs a reliable Python utility. Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐ŸŽฏ Your Task

Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค mark โ‰ค 100.

Example Input
67
Example Output
Grade = D
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsOrdered elif ConditionsMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Leap Year Validator

Core Skill: Nested Logical Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Leap Year Validator

Workshop Board needs a reliable Python utility. Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐ŸŽฏ Your Task

Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค year โ‰ค 9999.

Example Input
2000
Example Output
Leap Year
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsNested Logical ConditionsMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Triangle Inspector

Core Skill: Compound Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Triangle Inspector

Career Console needs a reliable Python utility. Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐ŸŽฏ Your Task

Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค each side โ‰ค 100000.

Example Input
3
4
5
Example Output
Scalene
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsCompound ConditionsMedium100 Points
CHALLENGE 16 Medium

Research Desk โ€” Number Classifier

Core Skill: if / elif / else

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Number Classifier

Research Desk needs a reliable Python utility. Read an integer and classify it as Positive, Negative or Zero.

๐ŸŽฏ Your Task

Read an integer and classify it as Positive, Negative or Zero.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-10^9 โ‰ค number โ‰ค 10^9.

Example Input
125
Example Output
Positive
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Decisionsif / elif / elseMedium100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Largest of Three

Core Skill: Chained Comparisons

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Largest of Three

Challenge Arena needs a reliable Python utility. Read three integers and display the largest value.

๐ŸŽฏ Your Task

Read three integers and display the largest value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Values may be equal and may be negative.

Example Input
100
100
25
Example Output
Largest = 100
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsChained ComparisonsHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Grade Boundary

Core Skill: Ordered elif Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Grade Boundary

Revision Room needs a reliable Python utility. Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐ŸŽฏ Your Task

Read a mark and print Grade = A, B, C, D or F using 90, 80, 70 and 60 as the boundaries.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค mark โ‰ค 100.

Example Input
48
Example Output
Grade = F
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsOrdered elif ConditionsHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Leap Year Validator

Core Skill: Nested Logical Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Leap Year Validator

Interview Lab needs a reliable Python utility. Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐ŸŽฏ Your Task

Read a year and determine whether it is a leap year under Gregorian calendar rules.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค year โ‰ค 9999.

Example Input
2023
Example Output
Not Leap Year
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsNested Logical ConditionsHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Triangle Inspector

Core Skill: Compound Conditions

DecisionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Triangle Inspector

CodeBhavya Hub needs a reliable Python utility. Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐ŸŽฏ Your Task

Read three positive side lengths. Print Invalid, Equilateral, Isosceles or Scalene.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค each side โ‰ค 100000.

Example Input
1
2
8
Example Output
Invalid
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DecisionsCompound ConditionsHard100 Points
๐Ÿ”Level 5 โ€” Loops & PatternsIteration, accumulators, digit logic and visual patterns. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Range Sum

Core Skill: for Loop and Accumulator

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Range Sum

Orientation Desk needs a reliable Python utility. Read n and calculate the sum of all integers from 1 through n using a loop.

๐ŸŽฏ Your Task

Read n and calculate the sum of all integers from 1 through n using a loop.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000.

Example Input
10
Example Output
Sum = 55
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopsfor Loop and AccumulatorEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Factorial Counter

Core Skill: Loop Multiplication

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Factorial Counter

Campus Portal needs a reliable Python utility. Read a non-negative integer and calculate its factorial.

๐ŸŽฏ Your Task

Read a non-negative integer and calculate its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
5
Example Output
Factorial = 120
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop MultiplicationEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Digit Sum Scanner

Core Skill: while Loop and Modulus

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Digit Sum Scanner

Learning Studio needs a reliable Python utility. Read a positive integer and calculate the sum of its digits.

๐ŸŽฏ Your Task

Read a positive integer and calculate the sum of its digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
48271
Example Output
Digit Sum = 22
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopswhile Loop and ModulusEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Five-Step Table

Core Skill: Loop-Controlled Output

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Five-Step Table

Skill Tracker needs a reliable Python utility. Read n and display the first five multiples in the exact n x i = product format.

๐ŸŽฏ Your Task

Read n and display the first five multiples in the exact n x i = product format.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค n โ‰ค 1000.

Example Input
3
Example Output
3 x 1 = 3
3 x 2 = 6
3 x 3 = 9
3 x 4 = 12
3 x 5 = 15
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop-Controlled OutputEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Growing Star Pattern

Core Skill: Nested Pattern Logic

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Growing Star Pattern

Mentor Console needs a reliable Python utility. Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐ŸŽฏ Your Task

Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 30.

Example Input
3
Example Output
*
**
***
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsNested Pattern LogicEasy100 Points
CHALLENGE 06 Easy

Library Counter โ€” Range Sum

Core Skill: for Loop and Accumulator

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Range Sum

Library Counter needs a reliable Python utility. Read n and calculate the sum of all integers from 1 through n using a loop.

๐ŸŽฏ Your Task

Read n and calculate the sum of all integers from 1 through n using a loop.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000.

Example Input
25
Example Output
Sum = 325
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopsfor Loop and AccumulatorEasy100 Points
CHALLENGE 07 Easy

Practice Lab โ€” Factorial Counter

Core Skill: Loop Multiplication

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Factorial Counter

Practice Lab needs a reliable Python utility. Read a non-negative integer and calculate its factorial.

๐ŸŽฏ Your Task

Read a non-negative integer and calculate its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
6
Example Output
Factorial = 720
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop MultiplicationEasy100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Digit Sum Scanner

Core Skill: while Loop and Modulus

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Digit Sum Scanner

Quiz Engine needs a reliable Python utility. Read a positive integer and calculate the sum of its digits.

๐ŸŽฏ Your Task

Read a positive integer and calculate the sum of its digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
9005
Example Output
Digit Sum = 14
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopswhile Loop and ModulusMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Five-Step Table

Core Skill: Loop-Controlled Output

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Five-Step Table

Project Hub needs a reliable Python utility. Read n and display the first five multiples in the exact n x i = product format.

๐ŸŽฏ Your Task

Read n and display the first five multiples in the exact n x i = product format.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค n โ‰ค 1000.

Example Input
7
Example Output
7 x 1 = 7
7 x 2 = 14
7 x 3 = 21
7 x 4 = 28
7 x 5 = 35
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop-Controlled OutputMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Growing Star Pattern

Core Skill: Nested Pattern Logic

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Growing Star Pattern

Placement Desk needs a reliable Python utility. Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐ŸŽฏ Your Task

Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 30.

Example Input
4
Example Output
*
**
***
****
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsNested Pattern LogicMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Range Sum

Core Skill: for Loop and Accumulator

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Range Sum

Team Dashboard needs a reliable Python utility. Read n and calculate the sum of all integers from 1 through n using a loop.

๐ŸŽฏ Your Task

Read n and calculate the sum of all integers from 1 through n using a loop.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000.

Example Input
50
Example Output
Sum = 1275
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopsfor Loop and AccumulatorMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Factorial Counter

Core Skill: Loop Multiplication

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Factorial Counter

Data Centre needs a reliable Python utility. Read a non-negative integer and calculate its factorial.

๐ŸŽฏ Your Task

Read a non-negative integer and calculate its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
7
Example Output
Factorial = 5040
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop MultiplicationMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Digit Sum Scanner

Core Skill: while Loop and Modulus

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Digit Sum Scanner

Student Vault needs a reliable Python utility. Read a positive integer and calculate the sum of its digits.

๐ŸŽฏ Your Task

Read a positive integer and calculate the sum of its digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
12345
Example Output
Digit Sum = 15
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopswhile Loop and ModulusMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Five-Step Table

Core Skill: Loop-Controlled Output

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Five-Step Table

Workshop Board needs a reliable Python utility. Read n and display the first five multiples in the exact n x i = product format.

๐ŸŽฏ Your Task

Read n and display the first five multiples in the exact n x i = product format.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค n โ‰ค 1000.

Example Input
12
Example Output
12 x 1 = 12
12 x 2 = 24
12 x 3 = 36
12 x 4 = 48
12 x 5 = 60
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop-Controlled OutputMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Growing Star Pattern

Core Skill: Nested Pattern Logic

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Growing Star Pattern

Career Console needs a reliable Python utility. Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐ŸŽฏ Your Task

Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 30.

Example Input
5
Example Output
*
**
***
****
*****
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsNested Pattern LogicMedium100 Points
CHALLENGE 16 Medium

Research Desk โ€” Range Sum

Core Skill: for Loop and Accumulator

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Range Sum

Research Desk needs a reliable Python utility. Read n and calculate the sum of all integers from 1 through n using a loop.

๐ŸŽฏ Your Task

Read n and calculate the sum of all integers from 1 through n using a loop.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000.

Example Input
100
Example Output
Sum = 5050
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopsfor Loop and AccumulatorMedium100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Factorial Counter

Core Skill: Loop Multiplication

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Factorial Counter

Challenge Arena needs a reliable Python utility. Read a non-negative integer and calculate its factorial.

๐ŸŽฏ Your Task

Read a non-negative integer and calculate its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
8
Example Output
Factorial = 40320
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop MultiplicationHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Digit Sum Scanner

Core Skill: while Loop and Modulus

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Digit Sum Scanner

Revision Room needs a reliable Python utility. Read a positive integer and calculate the sum of its digits.

๐ŸŽฏ Your Task

Read a positive integer and calculate the sum of its digits.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
80808
Example Output
Digit Sum = 24
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Loopswhile Loop and ModulusHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Five-Step Table

Core Skill: Loop-Controlled Output

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Five-Step Table

Interview Lab needs a reliable Python utility. Read n and display the first five multiples in the exact n x i = product format.

๐ŸŽฏ Your Task

Read n and display the first five multiples in the exact n x i = product format.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

-1000 โ‰ค n โ‰ค 1000.

Example Input
15
Example Output
15 x 1 = 15
15 x 2 = 30
15 x 3 = 45
15 x 4 = 60
15 x 5 = 75
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsLoop-Controlled OutputHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Growing Star Pattern

Core Skill: Nested Pattern Logic

LoopsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Growing Star Pattern

CodeBhavya Hub needs a reliable Python utility. Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐ŸŽฏ Your Task

Read n and print a left-aligned triangle containing one star on row 1 through n stars on row n.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 30.

Example Input
6
Example Output
*
**
***
****
*****
******
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
LoopsNested Pattern LogicHard100 Points
๐Ÿ”คLevel 6 โ€” StringsTraversal, slicing, normalisation and text analysis. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Vowel Frequency

Core Skill: String Traversal

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Vowel Frequency

Orientation Desk needs a reliable Python utility. Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐ŸŽฏ Your Task

Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains at most 1000 characters.

Example Input
CodeBhavya
Example Output
Vowels = 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString TraversalEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Normalised Palindrome

Core Skill: String Normalisation and Slicing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Normalised Palindrome

Campus Portal needs a reliable Python utility. Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐ŸŽฏ Your Task

Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The phrase contains at most 1000 characters.

Example Input
Never odd or even
Example Output
Palindrome
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString Normalisation and SlicingEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Reverse Word Order

Core Skill: split(), Slicing and join()

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Reverse Word Order

Learning Studio needs a reliable Python utility. Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐ŸŽฏ Your Task

Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence has 1 to 100 whitespace-separated words.

Example Input
learn practice build
Example Output
build practice learn
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Stringssplit(), Slicing and join()Easy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Character Counter

Core Skill: Character Frequency

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Character Counter

Skill Tracker needs a reliable Python utility. Read a text line and then one character. Print how many times that exact character occurs.

๐ŸŽฏ Your Task

Read a text line and then one character. Print how many times that exact character occurs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The character input contains exactly one character; matching is case-sensitive.

Example Input
banana
a
Example Output
Count = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsCharacter FrequencyEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Longest Word Finder

Core Skill: Word Processing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Longest Word Finder

Mentor Console needs a reliable Python utility. Read a sentence and print its longest word. If several words tie, print the first one.

๐ŸŽฏ Your Task

Read a sentence and print its longest word. If several words tie, print the first one.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains at least one word and at most 1000 characters.

Example Input
learn build grow
Example Output
Longest = learn
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsWord ProcessingEasy100 Points
CHALLENGE 06 Medium

Library Counter โ€” Vowel Frequency

Core Skill: String Traversal

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Vowel Frequency

Library Counter needs a reliable Python utility. Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐ŸŽฏ Your Task

Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains at most 1000 characters.

Example Input
Education
Example Output
Vowels = 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString TraversalMedium100 Points
CHALLENGE 07 Medium

Practice Lab โ€” Normalised Palindrome

Core Skill: String Normalisation and Slicing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Normalised Palindrome

Practice Lab needs a reliable Python utility. Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐ŸŽฏ Your Task

Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The phrase contains at most 1000 characters.

Example Input
A man a plan a canal Panama
Example Output
Palindrome
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString Normalisation and SlicingMedium100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Reverse Word Order

Core Skill: split(), Slicing and join()

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Reverse Word Order

Quiz Engine needs a reliable Python utility. Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐ŸŽฏ Your Task

Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence has 1 to 100 whitespace-separated words.

Example Input
python makes ideas real
Example Output
real ideas makes python
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Stringssplit(), Slicing and join()Medium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Character Counter

Core Skill: Character Frequency

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Character Counter

Project Hub needs a reliable Python utility. Read a text line and then one character. Print how many times that exact character occurs.

๐ŸŽฏ Your Task

Read a text line and then one character. Print how many times that exact character occurs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The character input contains exactly one character; matching is case-sensitive.

Example Input
mississippi
s
Example Output
Count = 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsCharacter FrequencyMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Longest Word Finder

Core Skill: Word Processing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Longest Word Finder

Placement Desk needs a reliable Python utility. Read a sentence and print its longest word. If several words tie, print the first one.

๐ŸŽฏ Your Task

Read a sentence and print its longest word. If several words tie, print the first one.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains at least one word and at most 1000 characters.

Example Input
Python makes automation enjoyable
Example Output
Longest = automation
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsWord ProcessingMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Vowel Frequency

Core Skill: String Traversal

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Vowel Frequency

Team Dashboard needs a reliable Python utility. Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐ŸŽฏ Your Task

Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains at most 1000 characters.

Example Input
Programming
Example Output
Vowels = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString TraversalMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Normalised Palindrome

Core Skill: String Normalisation and Slicing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Normalised Palindrome

Data Centre needs a reliable Python utility. Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐ŸŽฏ Your Task

Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The phrase contains at most 1000 characters.

Example Input
Python
Example Output
Not Palindrome
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString Normalisation and SlicingMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Reverse Word Order

Core Skill: split(), Slicing and join()

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Reverse Word Order

Student Vault needs a reliable Python utility. Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐ŸŽฏ Your Task

Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence has 1 to 100 whitespace-separated words.

Example Input
trace before you run
Example Output
run you before trace
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Stringssplit(), Slicing and join()Medium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Character Counter

Core Skill: Character Frequency

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Character Counter

Workshop Board needs a reliable Python utility. Read a text line and then one character. Print how many times that exact character occurs.

๐ŸŽฏ Your Task

Read a text line and then one character. Print how many times that exact character occurs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The character input contains exactly one character; matching is case-sensitive.

Example Input
CodeBhavya
o
Example Output
Count = 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsCharacter FrequencyMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Longest Word Finder

Core Skill: Word Processing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Longest Word Finder

Career Console needs a reliable Python utility. Read a sentence and print its longest word. If several words tie, print the first one.

๐ŸŽฏ Your Task

Read a sentence and print its longest word. If several words tie, print the first one.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains at least one word and at most 1000 characters.

Example Input
small clear functions
Example Output
Longest = functions
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsWord ProcessingMedium100 Points
CHALLENGE 16 Hard

Research Desk โ€” Vowel Frequency

Core Skill: String Traversal

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Vowel Frequency

Research Desk needs a reliable Python utility. Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐ŸŽฏ Your Task

Read one line of text and count its vowels without treating uppercase and lowercase differently.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains at most 1000 characters.

Example Input
AEIOU rhythm
Example Output
Vowels = 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString TraversalHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Normalised Palindrome

Core Skill: String Normalisation and Slicing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Normalised Palindrome

Challenge Arena needs a reliable Python utility. Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐ŸŽฏ Your Task

Read a phrase and determine whether it is a palindrome after ignoring spaces, punctuation and letter case.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The phrase contains at most 1000 characters.

Example Input
Was it a rat I saw
Example Output
Palindrome
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsString Normalisation and SlicingHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Reverse Word Order

Core Skill: split(), Slicing and join()

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Reverse Word Order

Revision Room needs a reliable Python utility. Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐ŸŽฏ Your Task

Read a sentence and print its words in reverse order without reversing the letters inside each word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence has 1 to 100 whitespace-separated words.

Example Input
clean code grows well
Example Output
well grows code clean
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
Stringssplit(), Slicing and join()Hard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Character Counter

Core Skill: Character Frequency

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Character Counter

Interview Lab needs a reliable Python utility. Read a text line and then one character. Print how many times that exact character occurs.

๐ŸŽฏ Your Task

Read a text line and then one character. Print how many times that exact character occurs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The character input contains exactly one character; matching is case-sensitive.

Example Input
assessment
s
Example Output
Count = 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsCharacter FrequencyHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Longest Word Finder

Core Skill: Word Processing

StringsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Longest Word Finder

CodeBhavya Hub needs a reliable Python utility. Read a sentence and print its longest word. If several words tie, print the first one.

๐ŸŽฏ Your Task

Read a sentence and print its longest word. If several words tie, print the first one.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains at least one word and at most 1000 characters.

Example Input
practice creates confidence
Example Output
Longest = confidence
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
StringsWord ProcessingHard100 Points
๐ŸงบLevel 7 โ€” Lists, Tuples & SetsSequence processing, uniqueness and set operations. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Even Value Collector

Core Skill: List Traversal and Filtering

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Even Value Collector

Orientation Desk needs a reliable Python utility. Read space-separated integers, print the even values in their original order, then print their sum.

๐ŸŽฏ Your Task

Read space-separated integers, print the even values in their original order, then print their sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
1 2 3 4 5 6
Example Output
2 4 6
Sum = 12
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsList Traversal and FilteringEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Second Largest Distinct

Core Skill: Lists, Sets and Sorting

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Second Largest Distinct

Campus Portal needs a reliable Python utility. Read at least two distinct integers and print the second-largest distinct value.

๐ŸŽฏ Your Task

Read at least two distinct integers and print the second-largest distinct value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 to 200 integers; at least two distinct values are guaranteed.

Example Input
5 1 9 9 7
Example Output
Second Largest = 7
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsLists, Sets and SortingEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Ordered Duplicate Remover

Core Skill: Order-Preserving List Logic

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Ordered Duplicate Remover

Learning Studio needs a reliable Python utility. Read integers and print only the first occurrence of each value while preserving the original order.

๐ŸŽฏ Your Task

Read integers and print only the first occurrence of each value while preserving the original order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 500 integers.

Example Input
3 1 3 2 1 5
Example Output
3 1 2 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsOrder-Preserving List LogicEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Common Unique Values

Core Skill: Set Intersection

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Common Unique Values

Skill Tracker needs a reliable Python utility. Read two lines of integers and print their common distinct values in ascending order.

๐ŸŽฏ Your Task

Read two lines of integers and print their common distinct values in ascending order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each line contains 1 to 200 integers.

Example Input
1 2 2 3
2 3 4
Example Output
2 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsSet IntersectionEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Tuple Statistics

Core Skill: Tuple Aggregation

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Tuple Statistics

Mentor Console needs a reliable Python utility. Read integers, store them as a tuple and display minimum, maximum and average.

๐ŸŽฏ Your Task

Read integers, store them as a tuple and display minimum, maximum and average.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
10 20 30 40
Example Output
Min = 10
Max = 40
Average = 25.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsTuple AggregationEasy100 Points
CHALLENGE 06 Medium

Library Counter โ€” Even Value Collector

Core Skill: List Traversal and Filtering

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Even Value Collector

Library Counter needs a reliable Python utility. Read space-separated integers, print the even values in their original order, then print their sum.

๐ŸŽฏ Your Task

Read space-separated integers, print the even values in their original order, then print their sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
8 11 14 17 20
Example Output
8 14 20
Sum = 42
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsList Traversal and FilteringMedium100 Points
CHALLENGE 07 Medium

Practice Lab โ€” Second Largest Distinct

Core Skill: Lists, Sets and Sorting

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Second Largest Distinct

Practice Lab needs a reliable Python utility. Read at least two distinct integers and print the second-largest distinct value.

๐ŸŽฏ Your Task

Read at least two distinct integers and print the second-largest distinct value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 to 200 integers; at least two distinct values are guaranteed.

Example Input
20 10 30 25
Example Output
Second Largest = 25
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsLists, Sets and SortingMedium100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Ordered Duplicate Remover

Core Skill: Order-Preserving List Logic

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Ordered Duplicate Remover

Quiz Engine needs a reliable Python utility. Read integers and print only the first occurrence of each value while preserving the original order.

๐ŸŽฏ Your Task

Read integers and print only the first occurrence of each value while preserving the original order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 500 integers.

Example Input
4 4 4 2 2 9
Example Output
4 2 9
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsOrder-Preserving List LogicMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Common Unique Values

Core Skill: Set Intersection

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Common Unique Values

Project Hub needs a reliable Python utility. Read two lines of integers and print their common distinct values in ascending order.

๐ŸŽฏ Your Task

Read two lines of integers and print their common distinct values in ascending order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each line contains 1 to 200 integers.

Example Input
5 8 9
1 5 9
Example Output
5 9
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsSet IntersectionMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Tuple Statistics

Core Skill: Tuple Aggregation

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Tuple Statistics

Placement Desk needs a reliable Python utility. Read integers, store them as a tuple and display minimum, maximum and average.

๐ŸŽฏ Your Task

Read integers, store them as a tuple and display minimum, maximum and average.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
5 8 11
Example Output
Min = 5
Max = 11
Average = 8.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsTuple AggregationMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Even Value Collector

Core Skill: List Traversal and Filtering

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Even Value Collector

Team Dashboard needs a reliable Python utility. Read space-separated integers, print the even values in their original order, then print their sum.

๐ŸŽฏ Your Task

Read space-separated integers, print the even values in their original order, then print their sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
2 2 2 3
Example Output
2 2 2
Sum = 6
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsList Traversal and FilteringMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Second Largest Distinct

Core Skill: Lists, Sets and Sorting

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Second Largest Distinct

Data Centre needs a reliable Python utility. Read at least two distinct integers and print the second-largest distinct value.

๐ŸŽฏ Your Task

Read at least two distinct integers and print the second-largest distinct value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 to 200 integers; at least two distinct values are guaranteed.

Example Input
4 4 3 2
Example Output
Second Largest = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsLists, Sets and SortingMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Ordered Duplicate Remover

Core Skill: Order-Preserving List Logic

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Ordered Duplicate Remover

Student Vault needs a reliable Python utility. Read integers and print only the first occurrence of each value while preserving the original order.

๐ŸŽฏ Your Task

Read integers and print only the first occurrence of each value while preserving the original order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 500 integers.

Example Input
1 2 3 1 2 4
Example Output
1 2 3 4
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsOrder-Preserving List LogicMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Common Unique Values

Core Skill: Set Intersection

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Common Unique Values

Workshop Board needs a reliable Python utility. Read two lines of integers and print their common distinct values in ascending order.

๐ŸŽฏ Your Task

Read two lines of integers and print their common distinct values in ascending order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each line contains 1 to 200 integers.

Example Input
10 20
30 40
Example Output
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsSet IntersectionMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Tuple Statistics

Core Skill: Tuple Aggregation

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Tuple Statistics

Career Console needs a reliable Python utility. Read integers, store them as a tuple and display minimum, maximum and average.

๐ŸŽฏ Your Task

Read integers, store them as a tuple and display minimum, maximum and average.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
100 50 75
Example Output
Min = 50
Max = 100
Average = 75.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsTuple AggregationMedium100 Points
CHALLENGE 16 Hard

Research Desk โ€” Even Value Collector

Core Skill: List Traversal and Filtering

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Even Value Collector

Research Desk needs a reliable Python utility. Read space-separated integers, print the even values in their original order, then print their sum.

๐ŸŽฏ Your Task

Read space-separated integers, print the even values in their original order, then print their sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
9 12 15 18 21
Example Output
12 18
Sum = 30
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsList Traversal and FilteringHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Second Largest Distinct

Core Skill: Lists, Sets and Sorting

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Second Largest Distinct

Challenge Arena needs a reliable Python utility. Read at least two distinct integers and print the second-largest distinct value.

๐ŸŽฏ Your Task

Read at least two distinct integers and print the second-largest distinct value.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 to 200 integers; at least two distinct values are guaranteed.

Example Input
100 50 75 100
Example Output
Second Largest = 75
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsLists, Sets and SortingHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Ordered Duplicate Remover

Core Skill: Order-Preserving List Logic

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Ordered Duplicate Remover

Revision Room needs a reliable Python utility. Read integers and print only the first occurrence of each value while preserving the original order.

๐ŸŽฏ Your Task

Read integers and print only the first occurrence of each value while preserving the original order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 500 integers.

Example Input
7 5 7 5 3
Example Output
7 5 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsOrder-Preserving List LogicHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Common Unique Values

Core Skill: Set Intersection

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Common Unique Values

Interview Lab needs a reliable Python utility. Read two lines of integers and print their common distinct values in ascending order.

๐ŸŽฏ Your Task

Read two lines of integers and print their common distinct values in ascending order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Each line contains 1 to 200 integers.

Example Input
3 6 9 12
6 12 18
Example Output
6 12
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsSet IntersectionHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Tuple Statistics

Core Skill: Tuple Aggregation

CollectionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Tuple Statistics

CodeBhavya Hub needs a reliable Python utility. Read integers, store them as a tuple and display minimum, maximum and average.

๐ŸŽฏ Your Task

Read integers, store them as a tuple and display minimum, maximum and average.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 200 integers.

Example Input
2 4 6 8 10
Example Output
Min = 2
Max = 10
Average = 6.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
CollectionsTuple AggregationHard100 Points
๐Ÿ—‚๏ธLevel 8 โ€” DictionariesCounting, lookup, grouping and record processing. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Sorted Word Frequency

Core Skill: Dictionary Counting

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Sorted Word Frequency

Orientation Desk needs a reliable Python utility. Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐ŸŽฏ Your Task

Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains 1 to 200 whitespace-separated words.

Example Input
learn build learn
Example Output
build:1
learn:2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary CountingEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Highest Scoring Student

Core Skill: Dictionary Records

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Highest Scoring Student

Campus Portal needs a reliable Python utility. Read n name-score records and print the name and mark of the first highest-scoring student.

๐ŸŽฏ Your Task

Read n name-score records and print the name and mark of the first highest-scoring student.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; names contain no spaces; 0 โ‰ค score โ‰ค 100.

Example Input
3
Asha 82
Ravi 75
Bhavya 91
Example Output
Bhavya 91
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary RecordsEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Dictionary Merger

Core Skill: Dictionary Update

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Dictionary Merger

Learning Studio needs a reliable Python utility. Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐ŸŽฏ Your Task

Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Keys are single words; values are integers; each line has at least one pair.

Example Input
a=1 b=2
b=5 c=3
Example Output
a=1 b=5 c=3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary UpdateEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” First-Letter Groups

Core Skill: Grouping with Dictionaries

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” First-Letter Groups

Skill Tracker needs a reliable Python utility. Read words and group them by first letter. Print groups in key order as letter:word,word.

๐ŸŽฏ Your Task

Read words and group them by first letter. Print groups in key order as letter:word,word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Words contain letters only and the line has at most 100 words.

Example Input
apple ant ball boat
Example Output
a:apple,ant
b:ball,boat
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesGrouping with DictionariesEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Inventory Lookup

Core Skill: Dictionary Lookup

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Inventory Lookup

Mentor Console needs a reliable Python utility. Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐ŸŽฏ Your Task

Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; item names contain no spaces; quantities are non-negative integers.

Example Input
3
pen 12
book 5
bag 2
book
Example Output
Available = 5
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary LookupEasy100 Points
CHALLENGE 06 Medium

Library Counter โ€” Sorted Word Frequency

Core Skill: Dictionary Counting

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Sorted Word Frequency

Library Counter needs a reliable Python utility. Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐ŸŽฏ Your Task

Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains 1 to 200 whitespace-separated words.

Example Input
python code python test
Example Output
code:1
python:2
test:1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary CountingMedium100 Points
CHALLENGE 07 Medium

Practice Lab โ€” Highest Scoring Student

Core Skill: Dictionary Records

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Highest Scoring Student

Practice Lab needs a reliable Python utility. Read n name-score records and print the name and mark of the first highest-scoring student.

๐ŸŽฏ Your Task

Read n name-score records and print the name and mark of the first highest-scoring student.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; names contain no spaces; 0 โ‰ค score โ‰ค 100.

Example Input
4
Dev 60
Isha 88
Kiran 79
Meera 95
Example Output
Meera 95
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary RecordsMedium100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Dictionary Merger

Core Skill: Dictionary Update

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Dictionary Merger

Quiz Engine needs a reliable Python utility. Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐ŸŽฏ Your Task

Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Keys are single words; values are integers; each line has at least one pair.

Example Input
x=10 y=20
z=30
Example Output
x=10 y=20 z=30
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary UpdateMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” First-Letter Groups

Core Skill: Grouping with Dictionaries

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” First-Letter Groups

Project Hub needs a reliable Python utility. Read words and group them by first letter. Print groups in key order as letter:word,word.

๐ŸŽฏ Your Task

Read words and group them by first letter. Print groups in key order as letter:word,word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Words contain letters only and the line has at most 100 words.

Example Input
cat car dog deer
Example Output
c:cat,car
d:dog,deer
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesGrouping with DictionariesMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Inventory Lookup

Core Skill: Dictionary Lookup

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Inventory Lookup

Placement Desk needs a reliable Python utility. Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐ŸŽฏ Your Task

Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; item names contain no spaces; quantities are non-negative integers.

Example Input
2
mouse 7
keyboard 4
monitor
Example Output
Not Found
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary LookupMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Sorted Word Frequency

Core Skill: Dictionary Counting

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Sorted Word Frequency

Team Dashboard needs a reliable Python utility. Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐ŸŽฏ Your Task

Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains 1 to 200 whitespace-separated words.

Example Input
red blue red green blue
Example Output
blue:2
green:1
red:2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary CountingMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Highest Scoring Student

Core Skill: Dictionary Records

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Highest Scoring Student

Data Centre needs a reliable Python utility. Read n name-score records and print the name and mark of the first highest-scoring student.

๐ŸŽฏ Your Task

Read n name-score records and print the name and mark of the first highest-scoring student.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; names contain no spaces; 0 โ‰ค score โ‰ค 100.

Example Input
2
Ana 70
Ben 65
Example Output
Ana 70
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary RecordsMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Dictionary Merger

Core Skill: Dictionary Update

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Dictionary Merger

Student Vault needs a reliable Python utility. Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐ŸŽฏ Your Task

Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Keys are single words; values are integers; each line has at least one pair.

Example Input
red=2 blue=4
blue=7 green=1
Example Output
blue=7 green=1 red=2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary UpdateMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” First-Letter Groups

Core Skill: Grouping with Dictionaries

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” First-Letter Groups

Workshop Board needs a reliable Python utility. Read words and group them by first letter. Print groups in key order as letter:word,word.

๐ŸŽฏ Your Task

Read words and group them by first letter. Print groups in key order as letter:word,word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Words contain letters only and the line has at most 100 words.

Example Input
python practice build better
Example Output
b:build,better
p:python,practice
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesGrouping with DictionariesMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Inventory Lookup

Core Skill: Dictionary Lookup

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Inventory Lookup

Career Console needs a reliable Python utility. Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐ŸŽฏ Your Task

Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; item names contain no spaces; quantities are non-negative integers.

Example Input
4
apple 9
banana 6
mango 3
grape 8
mango
Example Output
Available = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary LookupMedium100 Points
CHALLENGE 16 Hard

Research Desk โ€” Sorted Word Frequency

Core Skill: Dictionary Counting

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Sorted Word Frequency

Research Desk needs a reliable Python utility. Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐ŸŽฏ Your Task

Read a sentence, count each lowercase word and print word:count lines in alphabetical order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The sentence contains 1 to 200 whitespace-separated words.

Example Input
data drives decisions data
Example Output
data:2
decisions:1
drives:1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary CountingHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Highest Scoring Student

Core Skill: Dictionary Records

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Highest Scoring Student

Challenge Arena needs a reliable Python utility. Read n name-score records and print the name and mark of the first highest-scoring student.

๐ŸŽฏ Your Task

Read n name-score records and print the name and mark of the first highest-scoring student.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; names contain no spaces; 0 โ‰ค score โ‰ค 100.

Example Input
3
Pia 99
Raj 98
Sam 97
Example Output
Pia 99
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary RecordsHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Dictionary Merger

Core Skill: Dictionary Update

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Dictionary Merger

Revision Room needs a reliable Python utility. Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐ŸŽฏ Your Task

Read two key=value lines, merge them so the second line overrides duplicate keys, and print sorted key=value pairs.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Keys are single words; values are integers; each line has at least one pair.

Example Input
p=9 q=8
p=1 r=6
Example Output
p=1 q=8 r=6
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary UpdateHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” First-Letter Groups

Core Skill: Grouping with Dictionaries

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” First-Letter Groups

Interview Lab needs a reliable Python utility. Read words and group them by first letter. Print groups in key order as letter:word,word.

๐ŸŽฏ Your Task

Read words and group them by first letter. Print groups in key order as letter:word,word.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Words contain letters only and the line has at most 100 words.

Example Input
sun star moon map
Example Output
m:moon,map
s:sun,star
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesGrouping with DictionariesHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Inventory Lookup

Core Skill: Dictionary Lookup

DictionariesOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Inventory Lookup

CodeBhavya Hub needs a reliable Python utility. Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐ŸŽฏ Your Task

Read n item-quantity records and a query item. Print its available quantity or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100; item names contain no spaces; quantities are non-negative integers.

Example Input
1
python 100
python
Example Output
Available = 100
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
DictionariesDictionary LookupHard100 Points
๐ŸงฉLevel 9 โ€” Functions & RecursionReusable functions, recursion and structured decomposition. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Reusable Digit Sum

Core Skill: Function Definition and Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Reusable Digit Sum

Orientation Desk needs a reliable Python utility. Define digit_sum(number), read a positive integer and print the returned digit sum.

๐ŸŽฏ Your Task

Define digit_sum(number), read a positive integer and print the returned digit sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
48271
Example Output
Digit Sum = 22
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsFunction Definition and ReturnEasy100 Points
CHALLENGE 02 Easy

Campus Portal โ€” Recursive Factorial

Core Skill: Base Case and Recursive Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Recursive Factorial

Campus Portal needs a reliable Python utility. Define a recursive factorial(n), read n and print its factorial.

๐ŸŽฏ Your Task

Define a recursive factorial(n), read n and print its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
5
Example Output
Factorial = 120
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsBase Case and Recursive ReturnEasy100 Points
CHALLENGE 03 Easy

Learning Studio โ€” Recursive Fibonacci

Core Skill: Recursive Decomposition

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Recursive Fibonacci

Learning Studio needs a reliable Python utility. Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐ŸŽฏ Your Task

Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 30.

Example Input
7
Example Output
Fibonacci = 13
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsRecursive DecompositionEasy100 Points
CHALLENGE 04 Easy

Skill Tracker โ€” Variable-Length Average

Core Skill: Arbitrary Argument Functions

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Variable-Length Average

Skill Tracker needs a reliable Python utility. Define average(*values), read space-separated numbers and print their average to two decimal places.

๐ŸŽฏ Your Task

Define average(*values), read space-separated numbers and print their average to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 numbers.

Example Input
1 2 3 4
Example Output
Average = 2.50
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsArbitrary Argument FunctionsEasy100 Points
CHALLENGE 05 Easy

Mentor Console โ€” Prime Function

Core Skill: Reusable Boolean Function

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Prime Function

Mentor Console needs a reliable Python utility. Define is_prime(n), read an integer and print Prime or Not Prime.

๐ŸŽฏ Your Task

Define is_prime(n), read an integer and print Prime or Not Prime.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 10^9.

Example Input
29
Example Output
Prime
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsReusable Boolean FunctionEasy100 Points
CHALLENGE 06 Medium

Library Counter โ€” Reusable Digit Sum

Core Skill: Function Definition and Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Reusable Digit Sum

Library Counter needs a reliable Python utility. Define digit_sum(number), read a positive integer and print the returned digit sum.

๐ŸŽฏ Your Task

Define digit_sum(number), read a positive integer and print the returned digit sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
999
Example Output
Digit Sum = 27
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsFunction Definition and ReturnMedium100 Points
CHALLENGE 07 Medium

Practice Lab โ€” Recursive Factorial

Core Skill: Base Case and Recursive Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Recursive Factorial

Practice Lab needs a reliable Python utility. Define a recursive factorial(n), read n and print its factorial.

๐ŸŽฏ Your Task

Define a recursive factorial(n), read n and print its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
6
Example Output
Factorial = 720
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsBase Case and Recursive ReturnMedium100 Points
CHALLENGE 08 Medium

Quiz Engine โ€” Recursive Fibonacci

Core Skill: Recursive Decomposition

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Recursive Fibonacci

Quiz Engine needs a reliable Python utility. Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐ŸŽฏ Your Task

Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 30.

Example Input
8
Example Output
Fibonacci = 21
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsRecursive DecompositionMedium100 Points
CHALLENGE 09 Medium

Project Hub โ€” Variable-Length Average

Core Skill: Arbitrary Argument Functions

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Variable-Length Average

Project Hub needs a reliable Python utility. Define average(*values), read space-separated numbers and print their average to two decimal places.

๐ŸŽฏ Your Task

Define average(*values), read space-separated numbers and print their average to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 numbers.

Example Input
10 20 30
Example Output
Average = 20.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsArbitrary Argument FunctionsMedium100 Points
CHALLENGE 10 Medium

Placement Desk โ€” Prime Function

Core Skill: Reusable Boolean Function

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Prime Function

Placement Desk needs a reliable Python utility. Define is_prime(n), read an integer and print Prime or Not Prime.

๐ŸŽฏ Your Task

Define is_prime(n), read an integer and print Prime or Not Prime.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 10^9.

Example Input
35
Example Output
Not Prime
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsReusable Boolean FunctionMedium100 Points
CHALLENGE 11 Medium

Team Dashboard โ€” Reusable Digit Sum

Core Skill: Function Definition and Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Reusable Digit Sum

Team Dashboard needs a reliable Python utility. Define digit_sum(number), read a positive integer and print the returned digit sum.

๐ŸŽฏ Your Task

Define digit_sum(number), read a positive integer and print the returned digit sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
12003
Example Output
Digit Sum = 6
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsFunction Definition and ReturnMedium100 Points
CHALLENGE 12 Medium

Data Centre โ€” Recursive Factorial

Core Skill: Base Case and Recursive Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Recursive Factorial

Data Centre needs a reliable Python utility. Define a recursive factorial(n), read n and print its factorial.

๐ŸŽฏ Your Task

Define a recursive factorial(n), read n and print its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
7
Example Output
Factorial = 5040
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsBase Case and Recursive ReturnMedium100 Points
CHALLENGE 13 Medium

Student Vault โ€” Recursive Fibonacci

Core Skill: Recursive Decomposition

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Recursive Fibonacci

Student Vault needs a reliable Python utility. Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐ŸŽฏ Your Task

Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 30.

Example Input
9
Example Output
Fibonacci = 34
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsRecursive DecompositionMedium100 Points
CHALLENGE 14 Medium

Workshop Board โ€” Variable-Length Average

Core Skill: Arbitrary Argument Functions

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Variable-Length Average

Workshop Board needs a reliable Python utility. Define average(*values), read space-separated numbers and print their average to two decimal places.

๐ŸŽฏ Your Task

Define average(*values), read space-separated numbers and print their average to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 numbers.

Example Input
5 8 11
Example Output
Average = 8.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsArbitrary Argument FunctionsMedium100 Points
CHALLENGE 15 Medium

Career Console โ€” Prime Function

Core Skill: Reusable Boolean Function

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Prime Function

Career Console needs a reliable Python utility. Define is_prime(n), read an integer and print Prime or Not Prime.

๐ŸŽฏ Your Task

Define is_prime(n), read an integer and print Prime or Not Prime.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 10^9.

Example Input
2
Example Output
Prime
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsReusable Boolean FunctionMedium100 Points
CHALLENGE 16 Hard

Research Desk โ€” Reusable Digit Sum

Core Skill: Function Definition and Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Reusable Digit Sum

Research Desk needs a reliable Python utility. Define digit_sum(number), read a positive integer and print the returned digit sum.

๐ŸŽฏ Your Task

Define digit_sum(number), read a positive integer and print the returned digit sum.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค number โ‰ค 10^18.

Example Input
80808
Example Output
Digit Sum = 24
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsFunction Definition and ReturnHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Recursive Factorial

Core Skill: Base Case and Recursive Return

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Recursive Factorial

Challenge Arena needs a reliable Python utility. Define a recursive factorial(n), read n and print its factorial.

๐ŸŽฏ Your Task

Define a recursive factorial(n), read n and print its factorial.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 20.

Example Input
8
Example Output
Factorial = 40320
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsBase Case and Recursive ReturnHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Recursive Fibonacci

Core Skill: Recursive Decomposition

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Recursive Fibonacci

Revision Room needs a reliable Python utility. Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐ŸŽฏ Your Task

Define fibonacci(n), using F(0)=0 and F(1)=1, then print F(n).

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 30.

Example Input
10
Example Output
Fibonacci = 55
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsRecursive DecompositionHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Variable-Length Average

Core Skill: Arbitrary Argument Functions

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Variable-Length Average

Interview Lab needs a reliable Python utility. Define average(*values), read space-separated numbers and print their average to two decimal places.

๐ŸŽฏ Your Task

Define average(*values), read space-separated numbers and print their average to two decimal places.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 numbers.

Example Input
2 4 6 8 10
Example Output
Average = 6.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsArbitrary Argument FunctionsHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Prime Function

Core Skill: Reusable Boolean Function

FunctionsOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Prime Function

CodeBhavya Hub needs a reliable Python utility. Define is_prime(n), read an integer and print Prime or Not Prime.

๐ŸŽฏ Your Task

Define is_prime(n), read an integer and print Prime or Not Prime.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

0 โ‰ค n โ‰ค 10^9.

Example Input
97
Example Output
Prime
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
FunctionsReusable Boolean FunctionHard100 Points
๐Ÿ“Level 10 โ€” Modules, Exceptions & FilesTwenty genuine local labs for persistent data workflows. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Easy

Orientation Desk โ€” Text File Writer

Core Skill: Create and Write a File

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Text File Writer

Orientation Desk needs a genuine local Python workflow. Read one line from the keyboard and store it in notes.txt.

๐ŸŽฏ Your Task

Read one line from the keyboard and store it in notes.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Learning Python files
Example Output
Data written successfully
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCreate and Write a FileEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Open notes.txt with mode 'w' inside a with statement.
Show Program
text = input("Enter text: ")
with open("notes.txt", "w", encoding="utf-8") as file:
    file.write(text)
print("Data written successfully")
CHALLENGE 02 Easy

Campus Portal โ€” Text File Reader

Core Skill: Read a Complete File

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Text File Reader

Campus Portal needs a genuine local Python workflow. Read and display all text stored in notes.txt.

๐ŸŽฏ Your Task

Read and display all text stored in notes.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
notes.txt contains:
Learn
Practice
Build
Example Output
Learn
Practice
Build
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingRead a Complete FileEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Use file.read() inside a with open(..., 'r') block.
Show Program
with open("notes.txt", "r", encoding="utf-8") as file:
    content = file.read()
print(content, end="")
CHALLENGE 03 Easy

Learning Studio โ€” Line Counter

Core Skill: Count File Lines

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Line Counter

Learning Studio needs a genuine local Python workflow. Count the number of lines present in notes.txt.

๐ŸŽฏ Your Task

Count the number of lines present in notes.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
notes.txt contains 5 lines
Example Output
Lines = 5
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCount File LinesEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Iterate over the file and count one for every line.
Show Program
with open("notes.txt", "r", encoding="utf-8") as file:
    line_count = sum(1 for _ in file)
print("Lines =", line_count)
CHALLENGE 04 Easy

Skill Tracker โ€” Word Counter

Core Skill: Count File Words

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Word Counter

Skill Tracker needs a genuine local Python workflow. Count all whitespace-separated words in notes.txt.

๐ŸŽฏ Your Task

Count all whitespace-separated words in notes.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
notes.txt contains:
Python makes automation simple
Example Output
Words = 4
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCount File WordsEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Read the text, call split() and count the resulting items.
Show Program
with open("notes.txt", "r", encoding="utf-8") as file:
    words = file.read().split()
print("Words =", len(words))
CHALLENGE 05 Easy

Mentor Console โ€” Character Counter

Core Skill: Count File Characters

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Character Counter

Mentor Console needs a genuine local Python workflow. Count every character in notes.txt, including spaces and newlines.

๐ŸŽฏ Your Task

Count every character in notes.txt, including spaces and newlines.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
notes.txt contains:
Python
Example Output
Characters = 6
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCount File CharactersEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: len(file.read()) returns the number of characters read.
Show Program
with open("notes.txt", "r", encoding="utf-8") as file:
    content = file.read()
print("Characters =", len(content))
CHALLENGE 06 Easy

Library Counter โ€” Safe File Copier

Core Skill: Copy One File to Another

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Safe File Copier

Library Counter needs a genuine local Python workflow. Copy the complete contents of source.txt into backup.txt.

๐ŸŽฏ Your Task

Copy the complete contents of source.txt into backup.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
source.txt contains project notes
Example Output
File copied successfully
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCopy One File to AnotherEasy100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Read the source first, then open the destination in write mode.
Show Program
with open("source.txt", "r", encoding="utf-8") as source:
    content = source.read()
with open("backup.txt", "w", encoding="utf-8") as destination:
    destination.write(content)
print("File copied successfully")
CHALLENGE 07 Medium

Practice Lab โ€” Append Without Erasing

Core Skill: Append Mode

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Append Without Erasing

Practice Lab needs a genuine local Python workflow. Read one line and append it to journal.txt without deleting old data.

๐ŸŽฏ Your Task

Read one line and append it to journal.txt without deleting old data.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Completed Level 10
Example Output
Entry appended
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingAppend ModeMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Use mode 'a' and add a newline before or after the entry.
Show Program
entry = input("Enter entry: ")
with open("journal.txt", "a", encoding="utf-8") as file:
    file.write(entry + "\n")
print("Entry appended")
CHALLENGE 08 Medium

Quiz Engine โ€” Keyword Finder

Core Skill: Search Text in a File

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Keyword Finder

Quiz Engine needs a genuine local Python workflow. Read a keyword and report whether it occurs in notes.txt, ignoring letter case.

๐ŸŽฏ Your Task

Read a keyword and report whether it occurs in notes.txt, ignoring letter case.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
python
Example Output
Found
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingSearch Text in a FileMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Compare keyword.lower() with content.lower().
Show Program
keyword = input("Keyword: ").lower()
with open("notes.txt", "r", encoding="utf-8") as file:
    content = file.read().lower()
print("Found" if keyword in content else "Not Found")
CHALLENGE 09 Medium

Project Hub โ€” Specific Character Frequency

Core Skill: Character Search in Files

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Specific Character Frequency

Project Hub needs a genuine local Python workflow. Read one character and count its exact occurrences in notes.txt.

๐ŸŽฏ Your Task

Read one character and count its exact occurrences in notes.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
a
Example Output
Count = 3
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCharacter Search in FilesMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Read the complete file and use content.count(character).
Show Program
character = input("Character: ")
with open("notes.txt", "r", encoding="utf-8") as file:
    content = file.read()
print("Count =", content.count(character))
CHALLENGE 10 Medium

Placement Desk โ€” Number Archive Writer

Core Skill: Store Numeric Data

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Number Archive Writer

Placement Desk needs a genuine local Python workflow. Read space-separated integers and store one integer per line in numbers.txt.

๐ŸŽฏ Your Task

Read space-separated integers and store one integer per line in numbers.txt.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
10 20 30 40
Example Output
Numbers stored successfully
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingStore Numeric DataMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Convert each number to text and join with newline characters.
Show Program
numbers = list(map(int, input("Numbers: ").split()))
with open("numbers.txt", "w", encoding="utf-8") as file:
    file.write("\n".join(map(str, numbers)))
print("Numbers stored successfully")
CHALLENGE 11 Medium

Team Dashboard โ€” Number Archive Sum

Core Skill: Read and Aggregate File Data

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Number Archive Sum

Team Dashboard needs a genuine local Python workflow. Read integers from numbers.txt and display their sum.

๐ŸŽฏ Your Task

Read integers from numbers.txt and display their sum.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
numbers.txt contains:
10
20
30
Example Output
Sum = 60
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingRead and Aggregate File DataMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Convert every non-empty line to int before summing.
Show Program
with open("numbers.txt", "r", encoding="utf-8") as file:
    numbers = [int(line.strip()) for line in file if line.strip()]
print("Sum =", sum(numbers))
CHALLENGE 12 Medium

Data Centre โ€” CSV Student Register

Core Skill: csv Module

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” CSV Student Register

Data Centre needs a genuine local Python workflow. Write three name-and-score records into students.csv with a header row.

๐ŸŽฏ Your Task

Write three name-and-score records into students.csv with a header row.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Asha 91
Ravi 84
Meera 95
Example Output
CSV created
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File Handlingcsv ModuleMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Use csv.writer(), writerow() for the header and writerows() for the records.
Show Program
import csv

records = [("Asha", 91), ("Ravi", 84), ("Meera", 95)]
with open("students.csv", "w", newline="", encoding="utf-8") as file:
    writer = csv.writer(file)
    writer.writerow(["name", "score"])
    writer.writerows(records)
print("CSV created")
CHALLENGE 13 Medium

Student Vault โ€” JSON Settings Vault

Core Skill: json Module

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” JSON Settings Vault

Student Vault needs a genuine local Python workflow. Store a settings dictionary in settings.json and read it back.

๐ŸŽฏ Your Task

Store a settings dictionary in settings.json and read it back.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
theme=dark, language=Python
Example Output
{'theme': 'dark', 'language': 'Python'}
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File Handlingjson ModuleMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Use json.dump() to write and json.load() to read.
Show Program
import json

settings = {"theme": "dark", "language": "Python"}
with open("settings.json", "w", encoding="utf-8") as file:
    json.dump(settings, file, indent=2)
with open("settings.json", "r", encoding="utf-8") as file:
    loaded = json.load(file)
print(loaded)
CHALLENGE 14 Medium

Workshop Board โ€” Missing File Guard

Core Skill: FileNotFoundError Handling

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Missing File Guard

Workshop Board needs a genuine local Python workflow. Attempt to read report.txt and print a friendly message if it does not exist.

๐ŸŽฏ Your Task

Attempt to read report.txt and print a friendly message if it does not exist.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
report.txt is absent
Example Output
File not found
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingFileNotFoundError HandlingMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Place open() inside try and catch FileNotFoundError.
Show Program
try:
    with open("report.txt", "r", encoding="utf-8") as file:
        print(file.read(), end="")
except FileNotFoundError:
    print("File not found")
CHALLENGE 15 Medium

Career Console โ€” Path Inspector

Core Skill: pathlib Module

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Path Inspector

Career Console needs a genuine local Python workflow. Check whether data.txt exists and report File exists or File missing.

๐ŸŽฏ Your Task

Check whether data.txt exists and report File exists or File missing.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Run inside a local project folder
Example Output
File exists
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File Handlingpathlib ModuleMedium100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Create Path('data.txt') and call exists().
Show Program
from pathlib import Path

path = Path("data.txt")
print("File exists" if path.exists() else "File missing")
CHALLENGE 16 Hard

Research Desk โ€” Extension Inventory

Core Skill: Directory Traversal

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Extension Inventory

Research Desk needs a genuine local Python workflow. Count how many .py files are present in the current directory.

๐ŸŽฏ Your Task

Count how many .py files are present in the current directory.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Current project folder
Example Output
Python files = 6
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingDirectory TraversalHard100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Use Path('.').glob('*.py') and count the matches.
Show Program
from pathlib import Path

python_files = list(Path(".").glob("*.py"))
print("Python files =", len(python_files))
CHALLENGE 17 Hard

Challenge Arena โ€” Two-File Merger

Core Skill: Combine Text Files

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Two-File Merger

Challenge Arena needs a genuine local Python workflow. Combine first.txt and second.txt into merged.txt with a newline between their contents.

๐ŸŽฏ Your Task

Combine first.txt and second.txt into merged.txt with a newline between their contents.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
first.txt and second.txt
Example Output
Files merged
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCombine Text FilesHard100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Read both files before opening merged.txt in write mode.
Show Program
with open("first.txt", "r", encoding="utf-8") as first:
    first_text = first.read().rstrip("\n")
with open("second.txt", "r", encoding="utf-8") as second:
    second_text = second.read().lstrip("\n")
with open("merged.txt", "w", encoding="utf-8") as merged:
    merged.write(first_text + "\n" + second_text)
print("Files merged")
CHALLENGE 18 Hard

Revision Room โ€” Error Log Scanner

Core Skill: Log File Analysis

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Error Log Scanner

Revision Room needs a genuine local Python workflow. Count lines containing ERROR in application.log.

๐ŸŽฏ Your Task

Count lines containing ERROR in application.log.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
application.log contains mixed INFO and ERROR lines
Example Output
Errors = 4
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingLog File AnalysisHard100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Test 'ERROR' in line while iterating over the file.
Show Program
with open("application.log", "r", encoding="utf-8") as file:
    error_count = sum(1 for line in file if "ERROR" in line)
print("Errors =", error_count)
CHALLENGE 19 Hard

Interview Lab โ€” Blank-Line Cleaner

Core Skill: File Transformation

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Blank-Line Cleaner

Interview Lab needs a genuine local Python workflow. Create clean.txt from raw.txt while removing blank lines.

๐ŸŽฏ Your Task

Create clean.txt from raw.txt while removing blank lines.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
raw.txt contains empty lines
Example Output
Clean file created
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingFile TransformationHard100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Keep only lines for which line.strip() is non-empty.
Show Program
with open("raw.txt", "r", encoding="utf-8") as source:
    lines = [line for line in source if line.strip()]
with open("clean.txt", "w", encoding="utf-8") as destination:
    destination.writelines(lines)
print("Clean file created")
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Persistent Contact Book

Core Skill: CSV Records and Search

FilesLocal File Lab100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Persistent Contact Book

CodeBhavya Hub needs a genuine local Python workflow. Append a name and phone number to contacts.csv, then list all stored contacts.

๐ŸŽฏ Your Task

Append a name and phone number to contacts.csv, then list all stored contacts.

๐Ÿ“ฅ Input Format

Create the named local file or enter the requested data exactly as described.

๐Ÿ“ค Output Format

Produce the requested file or console result in the exact format shown.

๐Ÿ“ Constraints

Run this lab in a local Python 3 folder where file creation and persistent changes are allowed.

Example Input
Asha,9876543210
Example Output
Asha: 9876543210
Explanation: This is intentionally a local file lab so that real paths, file modes and persistent data are practised rather than simulated.
File HandlingCSV Records and SearchHard100 Points
๐Ÿ–ฅ๏ธ Local File Lab

This challenge intentionally uses real files on disk. Practise it in your local Python environment so file creation, append/copy operations, paths and persistent data behaviour are genuine rather than simulated as standard input.

๐Ÿ’ก Hint: Append with csv.writer(), then reopen in read mode with csv.reader().
Show Program
import csv

name = input("Name: ")
phone = input("Phone: ")
with open("contacts.csv", "a", newline="", encoding="utf-8") as file:
    csv.writer(file).writerow([name, phone])
with open("contacts.csv", "r", newline="", encoding="utf-8") as file:
    for saved_name, saved_phone in csv.reader(file):
        print(f"{saved_name}: {saved_phone}")
๐Ÿ—๏ธLevel 11 โ€” Object-Oriented PythonClasses, inheritance, encapsulation and polymorphism. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Medium

Orientation Desk โ€” Student Object Card

Core Skill: Class, __init__ and Method

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Student Object Card

Orientation Desk needs a reliable Python utility. Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐ŸŽฏ Your Task

Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one word; 0 โ‰ค score โ‰ค 100.

Example Input
Asha
91
Example Output
Asha scored 91
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass, __init__ and MethodMedium100 Points
CHALLENGE 02 Medium

Campus Portal โ€” Bank Account Guard

Core Skill: Encapsulation and Methods

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Bank Account Guard

Campus Portal needs a reliable Python utility. Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐ŸŽฏ Your Task

Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

All amounts are non-negative and at most 10^9.

Example Input
1000
250
400
Example Output
Balance = 850.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPEncapsulation and MethodsMedium100 Points
CHALLENGE 03 Medium

Learning Studio โ€” Shape Area Inheritance

Core Skill: Inheritance and Method Overriding

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Shape Area Inheritance

Learning Studio needs a reliable Python utility. Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐ŸŽฏ Your Task

Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Dimensions are positive and at most 100000.

Example Input
Rectangle
4
3
Example Output
Area = 12.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPInheritance and Method OverridingMedium100 Points
CHALLENGE 04 Medium

Skill Tracker โ€” Polymorphic Sound Board

Core Skill: Polymorphism

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Polymorphic Sound Board

Skill Tracker needs a reliable Python utility. Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐ŸŽฏ Your Task

Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The input contains only Dog, Cat and Cow separated by spaces.

Example Input
Dog Cat Cow
Example Output
Dog: Woof
Cat: Meow
Cow: Moo
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPPolymorphismMedium100 Points
CHALLENGE 05 Medium+

Mentor Console โ€” Product Object Counter

Core Skill: Class Attributes and Instances

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Product Object Counter

Mentor Console needs a reliable Python utility. Read product prices, create one Product object for each price, then display object count and total price.

๐ŸŽฏ Your Task

Read product prices, create one Product object for each price, then display object count and total price.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 non-negative prices.

Example Input
10 20 30
Example Output
Objects = 3
Total = 60.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass Attributes and InstancesMedium+100 Points
CHALLENGE 06 Medium+

Library Counter โ€” Student Object Card

Core Skill: Class, __init__ and Method

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Student Object Card

Library Counter needs a reliable Python utility. Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐ŸŽฏ Your Task

Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one word; 0 โ‰ค score โ‰ค 100.

Example Input
Ravi
84
Example Output
Ravi scored 84
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass, __init__ and MethodMedium+100 Points
CHALLENGE 07 Medium+

Practice Lab โ€” Bank Account Guard

Core Skill: Encapsulation and Methods

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Bank Account Guard

Practice Lab needs a reliable Python utility. Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐ŸŽฏ Your Task

Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

All amounts are non-negative and at most 10^9.

Example Input
500
100
700
Example Output
Insufficient Funds
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPEncapsulation and MethodsMedium+100 Points
CHALLENGE 08 Medium+

Quiz Engine โ€” Shape Area Inheritance

Core Skill: Inheritance and Method Overriding

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Shape Area Inheritance

Quiz Engine needs a reliable Python utility. Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐ŸŽฏ Your Task

Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Dimensions are positive and at most 100000.

Example Input
Square
5
Example Output
Area = 25.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPInheritance and Method OverridingMedium+100 Points
CHALLENGE 09 Medium+

Project Hub โ€” Polymorphic Sound Board

Core Skill: Polymorphism

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Polymorphic Sound Board

Project Hub needs a reliable Python utility. Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐ŸŽฏ Your Task

Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The input contains only Dog, Cat and Cow separated by spaces.

Example Input
Cat Dog
Example Output
Cat: Meow
Dog: Woof
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPPolymorphismMedium+100 Points
CHALLENGE 10 Medium+

Placement Desk โ€” Product Object Counter

Core Skill: Class Attributes and Instances

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Product Object Counter

Placement Desk needs a reliable Python utility. Read product prices, create one Product object for each price, then display object count and total price.

๐ŸŽฏ Your Task

Read product prices, create one Product object for each price, then display object count and total price.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 non-negative prices.

Example Input
99.5 50.5
Example Output
Objects = 2
Total = 150.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass Attributes and InstancesMedium+100 Points
CHALLENGE 11 Medium+

Team Dashboard โ€” Student Object Card

Core Skill: Class, __init__ and Method

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Student Object Card

Team Dashboard needs a reliable Python utility. Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐ŸŽฏ Your Task

Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one word; 0 โ‰ค score โ‰ค 100.

Example Input
Meera
95
Example Output
Meera scored 95
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass, __init__ and MethodMedium+100 Points
CHALLENGE 12 Medium+

Data Centre โ€” Bank Account Guard

Core Skill: Encapsulation and Methods

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Bank Account Guard

Data Centre needs a reliable Python utility. Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐ŸŽฏ Your Task

Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

All amounts are non-negative and at most 10^9.

Example Input
2000
500
250
Example Output
Balance = 2250.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPEncapsulation and MethodsMedium+100 Points
CHALLENGE 13 Medium+

Student Vault โ€” Shape Area Inheritance

Core Skill: Inheritance and Method Overriding

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Shape Area Inheritance

Student Vault needs a reliable Python utility. Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐ŸŽฏ Your Task

Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Dimensions are positive and at most 100000.

Example Input
Rectangle
2.5
8
Example Output
Area = 20.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPInheritance and Method OverridingMedium+100 Points
CHALLENGE 14 Medium+

Workshop Board โ€” Polymorphic Sound Board

Core Skill: Polymorphism

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Polymorphic Sound Board

Workshop Board needs a reliable Python utility. Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐ŸŽฏ Your Task

Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The input contains only Dog, Cat and Cow separated by spaces.

Example Input
Cow Cow Dog
Example Output
Cow: Moo
Cow: Moo
Dog: Woof
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPPolymorphismMedium+100 Points
CHALLENGE 15 Hard

Career Console โ€” Product Object Counter

Core Skill: Class Attributes and Instances

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Product Object Counter

Career Console needs a reliable Python utility. Read product prices, create one Product object for each price, then display object count and total price.

๐ŸŽฏ Your Task

Read product prices, create one Product object for each price, then display object count and total price.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 non-negative prices.

Example Input
7 8 9 10
Example Output
Objects = 4
Total = 34.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass Attributes and InstancesHard100 Points
CHALLENGE 16 Hard

Research Desk โ€” Student Object Card

Core Skill: Class, __init__ and Method

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Student Object Card

Research Desk needs a reliable Python utility. Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐ŸŽฏ Your Task

Create a Student class with name and score, then display '<name> scored <score>' through an instance method.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Name is one word; 0 โ‰ค score โ‰ค 100.

Example Input
Kiran
78
Example Output
Kiran scored 78
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass, __init__ and MethodHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Bank Account Guard

Core Skill: Encapsulation and Methods

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Bank Account Guard

Challenge Arena needs a reliable Python utility. Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐ŸŽฏ Your Task

Model an account, deposit an amount, then withdraw if sufficient funds remain. Print the final balance or Insufficient Funds.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

All amounts are non-negative and at most 10^9.

Example Input
750
50
300
Example Output
Balance = 500.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPEncapsulation and MethodsHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Shape Area Inheritance

Core Skill: Inheritance and Method Overriding

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Shape Area Inheritance

Revision Room needs a reliable Python utility. Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐ŸŽฏ Your Task

Create a base Shape and Rectangle/Square subclasses that return area. Read the shape data and print Area to two decimals.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

Dimensions are positive and at most 100000.

Example Input
Square
7
Example Output
Area = 49.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPInheritance and Method OverridingHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Polymorphic Sound Board

Core Skill: Polymorphism

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Polymorphic Sound Board

Interview Lab needs a reliable Python utility. Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐ŸŽฏ Your Task

Read animal types and create matching objects whose speak() methods produce Dog: Woof, Cat: Meow or Cow: Moo.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The input contains only Dog, Cat and Cow separated by spaces.

Example Input
Dog
Example Output
Dog: Woof
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPPolymorphismHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Product Object Counter

Core Skill: Class Attributes and Instances

OOPOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Product Object Counter

CodeBhavya Hub needs a reliable Python utility. Read product prices, create one Product object for each price, then display object count and total price.

๐ŸŽฏ Your Task

Read product prices, create one Product object for each price, then display object count and total price.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains 1 to 100 non-negative prices.

Example Input
100
Example Output
Objects = 1
Total = 100.00
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
OOPClass Attributes and InstancesHard100 Points
๐Ÿ†Level 12 โ€” Advanced Python & PlacementInterview algorithms, efficient structures and clean reasoning. โ€ข 20 original CodeBhavya challenges
Open 20 Challenges

Every challenge preserves the learning objective of this level while using CodeBhavya story framing, explicit requirements and progressive difficulty.

CHALLENGE 01 Medium

Orientation Desk โ€” Two-Sum Indices

Core Skill: Hash Map Lookup

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Orientation Desk โ€” Two-Sum Indices

Orientation Desk needs a reliable Python utility. Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐ŸŽฏ Your Task

Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 โ‰ค list length โ‰ค 100000; exactly one best first-found pair may exist.

Example Input
9
2 7 11 15
Example Output
0 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHash Map LookupMedium100 Points
CHALLENGE 02 Medium

Campus Portal โ€” Balanced Brackets

Core Skill: Stack

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Campus Portal โ€” Balanced Brackets

Campus Portal needs a reliable Python utility. Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐ŸŽฏ Your Task

Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains only ()[]{} and has length at most 100000.

Example Input
{[()]}
Example Output
Balanced
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementStackMedium100 Points
CHALLENGE 03 Medium

Learning Studio โ€” Maximum Subarray Sum

Core Skill: Kadane's Algorithm

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Learning Studio โ€” Maximum Subarray Sum

Learning Studio needs a reliable Python utility. Read integers and print the largest sum of any non-empty contiguous subarray.

๐ŸŽฏ Your Task

Read integers and print the largest sum of any non-empty contiguous subarray.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; each value lies between -10^9 and 10^9.

Example Input
-2 1 -3 4 -1 2 1 -5 4
Example Output
Maximum Sum = 6
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementKadane's AlgorithmMedium100 Points
CHALLENGE 04 Medium

Skill Tracker โ€” Binary Search

Core Skill: O(log n) Search

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Skill Tracker โ€” Binary Search

Skill Tracker needs a reliable Python utility. Read a sorted integer list and a target, then print its zero-based index or -1.

๐ŸŽฏ Your Task

Read a sorted integer list and a target, then print its zero-based index or -1.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; input values are sorted in ascending order.

Example Input
1 3 5 7 9
7
Example Output
Index = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementO(log n) SearchMedium100 Points
CHALLENGE 05 Medium+

Mentor Console โ€” Most Frequent Word

Core Skill: Hashing and Tie Breaking

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Mentor Console โ€” Most Frequent Word

Mentor Console needs a reliable Python utility. Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐ŸŽฏ Your Task

Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 to 100000 lowercase words.

Example Input
code python code learn
Example Output
code 2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHashing and Tie BreakingMedium+100 Points
CHALLENGE 06 Medium+

Library Counter โ€” Two-Sum Indices

Core Skill: Hash Map Lookup

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Library Counter โ€” Two-Sum Indices

Library Counter needs a reliable Python utility. Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐ŸŽฏ Your Task

Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 โ‰ค list length โ‰ค 100000; exactly one best first-found pair may exist.

Example Input
6
3 2 4
Example Output
1 2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHash Map LookupMedium+100 Points
CHALLENGE 07 Medium+

Practice Lab โ€” Balanced Brackets

Core Skill: Stack

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Practice Lab โ€” Balanced Brackets

Practice Lab needs a reliable Python utility. Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐ŸŽฏ Your Task

Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains only ()[]{} and has length at most 100000.

Example Input
([)]
Example Output
Not Balanced
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementStackMedium+100 Points
CHALLENGE 08 Medium+

Quiz Engine โ€” Maximum Subarray Sum

Core Skill: Kadane's Algorithm

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Quiz Engine โ€” Maximum Subarray Sum

Quiz Engine needs a reliable Python utility. Read integers and print the largest sum of any non-empty contiguous subarray.

๐ŸŽฏ Your Task

Read integers and print the largest sum of any non-empty contiguous subarray.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; each value lies between -10^9 and 10^9.

Example Input
5 -2 3 4
Example Output
Maximum Sum = 10
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementKadane's AlgorithmMedium+100 Points
CHALLENGE 09 Medium+

Project Hub โ€” Binary Search

Core Skill: O(log n) Search

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Project Hub โ€” Binary Search

Project Hub needs a reliable Python utility. Read a sorted integer list and a target, then print its zero-based index or -1.

๐ŸŽฏ Your Task

Read a sorted integer list and a target, then print its zero-based index or -1.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; input values are sorted in ascending order.

Example Input
2 4 6 8 10
5
Example Output
Index = -1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementO(log n) SearchMedium+100 Points
CHALLENGE 10 Medium+

Placement Desk โ€” Most Frequent Word

Core Skill: Hashing and Tie Breaking

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Placement Desk โ€” Most Frequent Word

Placement Desk needs a reliable Python utility. Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐ŸŽฏ Your Task

Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 to 100000 lowercase words.

Example Input
red blue red green blue
Example Output
blue 2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHashing and Tie BreakingMedium+100 Points
CHALLENGE 11 Medium+

Team Dashboard โ€” Two-Sum Indices

Core Skill: Hash Map Lookup

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Team Dashboard โ€” Two-Sum Indices

Team Dashboard needs a reliable Python utility. Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐ŸŽฏ Your Task

Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 โ‰ค list length โ‰ค 100000; exactly one best first-found pair may exist.

Example Input
10
1 3 5 7 9
Example Output
1 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHash Map LookupMedium+100 Points
CHALLENGE 12 Medium+

Data Centre โ€” Balanced Brackets

Core Skill: Stack

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Data Centre โ€” Balanced Brackets

Data Centre needs a reliable Python utility. Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐ŸŽฏ Your Task

Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains only ()[]{} and has length at most 100000.

Example Input
(()[])
Example Output
Balanced
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementStackMedium+100 Points
CHALLENGE 13 Medium+

Student Vault โ€” Maximum Subarray Sum

Core Skill: Kadane's Algorithm

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Student Vault โ€” Maximum Subarray Sum

Student Vault needs a reliable Python utility. Read integers and print the largest sum of any non-empty contiguous subarray.

๐ŸŽฏ Your Task

Read integers and print the largest sum of any non-empty contiguous subarray.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; each value lies between -10^9 and 10^9.

Example Input
-8 -3 -6 -2 -5 -4
Example Output
Maximum Sum = -2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementKadane's AlgorithmMedium+100 Points
CHALLENGE 14 Medium+

Workshop Board โ€” Binary Search

Core Skill: O(log n) Search

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Workshop Board โ€” Binary Search

Workshop Board needs a reliable Python utility. Read a sorted integer list and a target, then print its zero-based index or -1.

๐ŸŽฏ Your Task

Read a sorted integer list and a target, then print its zero-based index or -1.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; input values are sorted in ascending order.

Example Input
-5 0 4 11
-5
Example Output
Index = 0
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementO(log n) SearchMedium+100 Points
CHALLENGE 15 Hard

Career Console โ€” Most Frequent Word

Core Skill: Hashing and Tie Breaking

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Career Console โ€” Most Frequent Word

Career Console needs a reliable Python utility. Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐ŸŽฏ Your Task

Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 to 100000 lowercase words.

Example Input
one two three
Example Output
one 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHashing and Tie BreakingHard100 Points
CHALLENGE 16 Hard

Research Desk โ€” Two-Sum Indices

Core Skill: Hash Map Lookup

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Research Desk โ€” Two-Sum Indices

Research Desk needs a reliable Python utility. Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐ŸŽฏ Your Task

Read a target and a list of integers. Print the zero-based indices of the first pair whose sum is target, or Not Found.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

2 โ‰ค list length โ‰ค 100000; exactly one best first-found pair may exist.

Example Input
14
8 6 2 12
Example Output
0 1
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHash Map LookupHard100 Points
CHALLENGE 17 Hard

Challenge Arena โ€” Balanced Brackets

Core Skill: Stack

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Challenge Arena โ€” Balanced Brackets

Challenge Arena needs a reliable Python utility. Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐ŸŽฏ Your Task

Read a bracket string and print Balanced only when every bracket closes in the correct order.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

The line contains only ()[]{} and has length at most 100000.

Example Input
{}[]
Example Output
Balanced
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementStackHard100 Points
CHALLENGE 18 Hard

Revision Room โ€” Maximum Subarray Sum

Core Skill: Kadane's Algorithm

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Revision Room โ€” Maximum Subarray Sum

Revision Room needs a reliable Python utility. Read integers and print the largest sum of any non-empty contiguous subarray.

๐ŸŽฏ Your Task

Read integers and print the largest sum of any non-empty contiguous subarray.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; each value lies between -10^9 and 10^9.

Example Input
1 2 3 4
Example Output
Maximum Sum = 10
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementKadane's AlgorithmHard100 Points
CHALLENGE 19 Hard

Interview Lab โ€” Binary Search

Core Skill: O(log n) Search

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

Interview Lab โ€” Binary Search

Interview Lab needs a reliable Python utility. Read a sorted integer list and a target, then print its zero-based index or -1.

๐ŸŽฏ Your Task

Read a sorted integer list and a target, then print its zero-based index or -1.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 โ‰ค n โ‰ค 100000; input values are sorted in ascending order.

Example Input
10 20 30 40
40
Example Output
Index = 3
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementO(log n) SearchHard100 Points
CHALLENGE 20 Hard

CodeBhavya Hub โ€” Most Frequent Word

Core Skill: Hashing and Tie Breaking

PlacementOnline Judge100 Points
View Challenge โ†’
CODEBHAVYA ORIGINAL CHALLENGE

CodeBhavya Hub โ€” Most Frequent Word

CodeBhavya Hub needs a reliable Python utility. Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐ŸŽฏ Your Task

Read lowercase words and print the most frequent word with its count. Break ties alphabetically.

๐Ÿ“ฅ Input Format

Read the required value or values from standard input in the order shown.

๐Ÿ“ค Output Format

Print only the requested result in the exact format shown.

๐Ÿ“ Constraints

1 to 100000 lowercase words.

Example Input
practice makes progress practice
Example Output
practice 2
Explanation: The sample demonstrates the required behaviour. Follow the same input/output contract for every valid test case.
PlacementHashing and Tie BreakingHard100 Points

Practice rule: Try the problem before opening the hint. Viewing a hint limits the competitive score to 90; viewing the official program changes the result to โ€œcompleted with solutionโ€. Progress is stored in this browser.