What would output this code? print(hello world)

It would be an error since you can only print a string. To make a string we must have "" or str() print("hello world")

TJ

Related Python Mentoring answers

All answers ▸

What would you expect to be the output of the following code snippet: `a = [1, 2, 3]; b = a; b[1] = 4; print(a); print(b);`, and why?


How do I define a function in Python?


Explain why creating a list of several instances of one element using something like my_list = [a] * 5 can result in strange behaviour


Create a program that generates prime numbers between two integer boundareis