Loading...

print_input_demo
Key Stage 4
Year 10
Computer Science
Here are the three lines of code in the editor. Let's see what happens when we run the code. So let's run line 1. So it's asking, "What is your name?" So I'll put my name in. So this will become the value that is stored in the user variable. It's Matt. Press enter. And then it runs line 3, so it outputs "Hello," and the value that's held in the variable user, which in this case is "Matt.".
print_input_demo
Key Stage 4
Year 10
Computer Science
Here are the three lines of code in the editor. Let's see what happens when we run the code. So let's run line 1. So it's asking, "What is your name?" So I'll put my name in. So this will become the value that is stored in the user variable. It's Matt. Press enter. And then it runs line 3, so it outputs "Hello," and the value that's held in the variable user, which in this case is "Matt.".