Previous Next
0 / 8
Module DEMO-32-55DEMO-C-32

Case Converter

DEMO-C-32 โ€ข Programming in C

Browser-only practice

Problem Statement

Write a program that reads a single uppercase letter from the user and converts it to lowercase by adding 32 to its ASCII value.

In ASCII encoding, uppercase letters (A-Z) have values from 65-90, while their lowercase counterparts (a-z) have values from 97-122. The difference between any uppercase letter and its lowercase equivalent is exactly 32.

Your task is to read one character from standard input, add 32 to its ASCII value, and print the resulting lowercase character.

Constraints

The input will always be a single uppercase letter (A-Z).

Input Format

A single uppercase letter (A-Z) on one line.

Output Format

A single lowercase letter (a-z) on one line.

Sample Testcases

Submit runs every public testcase in this browser. Results and code never leave this device.

Sample #1
Public sample
A
a
ASCII value of 'A' is 65. Adding 32 gives 97, which is the ASCII value of 'a'.

Web terminal

C, C++, Java, and Python run locally in a browser VM. No worker or visualizer is used.

Saved in this browser
Editor settings