Answers for "print " in python"

7

python print

#Normal:#
print("Hiya Grepper!") #Output: Hiya Grepper!#
#As Equation:#
print(1+1)  #Output: 2#
#With String Variables:#
x = 'Pog'
print(x + 'Champ') #Output: PogChamp#
#With Integer Variables:#
y = 9999
z = str(y)
print('You have ' + z + ' IQ') #Output: You have 9999 IQ#
#NOTE: Not converting the int variable to a str variable will return an error#
Posted by: Guest on August-09-2020
3

python print

print("type what you want to be printed")
Posted by: Guest on July-06-2020
0

print in python

# Print statements in python

# A usual print() statement looks like this:

print("Hello from the print statement!")

#   A print statement starts with print( , as it is a built-in function

# It contains any given value that can be printed to the console. (ex. "Hello!")

# It ends with a closed bracket

# A few more examples:


name = input("Enter a name :\n") # asks for a name
print(f"Your name is {name}") # Your name is <whatever name you entered>

print(1 + 2) # 3

print(not True and not False) # False
Posted by: Guest on December-20-2020

Python Answers by Framework

Browse Popular Code Answers by Language