Hello World

Problem Statement

This section contains a brief description about the problem, and the solution we need to find. For example,

Company Abc has a display board at its front gate to greet its employees with a message.

Write a program read an the message, and then print it to the display board.

Input

This section details on the type of input the program takes. For example,

The first line of input consists of a string which represents the message the company would like to display.

Output

This section details on the program output. For example,

Print the given message as is to standard output.

As is

This section details on what that is already there in the program. For example,

The boilerplate code is already there to read the input from user, in the main() function. Do not edit this code.

To do ✍

This section details on what needs to be done by you. For example,

deliverMessage() has a parameter: message. In this function, write a print() statement to print the given message.

And now there are some examples below. The examples contain a sample input, and the expected output. Occasionally, it also contains explanation, if the example needs any.

Example 1

Test input

Hello World

Test output

Hello World

Example 2

Test input

Hello everyone!

Test output

Hello everyone!

Program on the right side panel

There is the incomplete program on the right side panel. Once you complete the code, you can click on the Run Tests button. A section slides up with the test cases, and the test cases are run for the program. If all the tests are passed, you can continue with the next challenge. If at all any tests are not passed, you can either check your program again, or you may run the test cases again, just in case if you are sure that the program is correct.

Reset button, resets the program to the initial version.

Download button lets you download the current program in the program panel.

If you would like to know the solution, you can click on the show answer button floating in the bottom right corner of the program panel. When you click on it, the program solution is displayed below.

Python Program

# Complete the following function
def deliverMessage(message):
    

# Boilerplate code - Do not edit the following
def main():
    message = input()
    deliverMessage(message)

if __name__ == "__main__":
    main()

Input and Outputs 1

Hello World
Hello World

Input and Outputs 2

apple banana
apple banana
# Complete the following function
def deliverMessage(message):
    print(message)

# Boilerplate code - Do not edit the following
def main():
    message = input()
    deliverMessage(message)

if __name__ == "__main__":
    main()
show answer
main.py
⏵︎ Run Tests
Reset
Download
×
Code copied to clipboard successfully 👍