What is Python?

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

To perform addition in Python we use the answer choices a. + b. - c. / d. *

a. +

What is a output? answer choices a. A piece of data that is shown on the screen. b. Data that the user enters c. An output d. A orange

a. A piece of data that is shown on the screen.

Which of the following functions is a built-in function in python? answer choices a) factorial() b) print() c) seed() d) sqrt()

b) print()

To create a comment in Python you use? answer choices a. @ b. # c. % d. $

b. #

An error that cause a program to crash is a.. answer choices a. Syntax b. Run Time c. Logic Error

b. Run Time

The hardest type of error to detect is a? answer choices a. Syntax b. Run Time c. Logic Error

c. Logic Error

f-strings allow you to do... answer choices a. Place strings into a variable and format it as a variable. b. Nothing c. Place variables into a string and format it as text. d. Place strings into a variable and format it as text.

c. Place variables into a string and format it as text.

The escape sequence for a backslash character is? answer choices a. \ b. / c. \\ d. //

c. \\

Which statement prints 7 (Select 2 answers) answer choices a. print 7 b. print("7" c. print("7") d. print(3 + 4)

c. print("7") d. print(3 + 4)

Which statement prints I am 10 years old? answer choices a. pint("I am 10 years old.") b. print('I am 10 years old.) c. print('')I am 10 years old. d. print("I am 10 years old.")

d. print("I am 10 years old.")

Floats are... answer choices a. Decimals b. Whole Numbers c. Integers d. Extra Decimals

a. Decimals

What does the term 'debug' mean? answer choices a. Identify errors and fix them. b. Making a calculation c. A set of instructions d. Looking at code

a. Identify errors and fix them.

What will the output be from the following Python code? Print("Hello world!") answer choices a. NameError b. Hello world! c. "Hello world" d. Print(Hello world!)

a. NameError

Errors in the rules of the language are known as? answer choices a. Syntax b. Run TIme c. Logic

a. Syntax

A function is a mini program that runs and returns a value to your program. answer choices a. True b. False

a. True

The print( ) function can be used with a combination of text and variables? answer choices a. True b. False

a. True

The escape sequence for a double quote is? answer choices a. \" b. /" c. \\" d. //"

a. \"

The escape sequence for a single quote is? answer choices a. \' b. /' c. \\' d. //'

a. \'

What is the Python built-in function used to display numbers and text on the screen? answer choices a. print b. input c. output d. command

a. print

What function is used to output a message in python? answer choices a. print("") b. input=name c. print d. name=input

a. print("")

Which of the following character is used to give single-line comments in Python? answer choices a) // b) # c) ! d) /*

b) #

To perform subtraction in Python we use the answer choices a. + b. - c. / d. *

b. -

Strings can be added together using what process? answer choices a. Float b. Concatenation c. Integers d. Variable

b. Concatenation

The f, in f-strings, stands for? answer choices a. Fun b. Format c. Function d. Form

b. Format

.lower( ) makes all your text? answer choices a. Snake Case b. Lower Case c. Capitalized d. Initial Caps

b. Lower Case

A series of characters (letters, numbers, and spaces). Always enclosed in quotes. answer choices a. print( ) b. String c. Variable d. Runtime Error

b. String

What is syntax? answer choices a. Syntax is the word used to describe an error b. Syntax is the rules of the programming language c. It is used to read information d. It is used to output information

b. Syntax is the rules of the programming language

What will the output be from the following code? print(Hello world!) a. Hello world! b. SyntaxError c. Hello world d. print(Hello world!)

b. SyntaxError

This is a placeholder for a value. answer choices a. String b. Variable c. Integer d. Method

b. Variable

Integers are... answer choices a. Decimals b. Whole Numbers c. Floats d. Extra Decimals

b. Whole Numbers

Which of the following is the correct extension of the Python file? answer choices a) .python b) .pl c) .py d) .p

c) .py

Who developed Python Programming Language? answer choices a) Wick van Rossum b) Rasmus Lerdorf c) Guido van Rossum d) Niene Stom

c) Guido van Rossum

To use exponents in Python we use the answer choices a. + b. - c. ** d. *

c. **

To perform division in Python we use the answer choices a. + b. - c. / d. *

c. /

.upper( ) makes all your text? answer choices a. Snake Case b. Lower Case c. Capitalized d. Initial Caps

c. Capitalized

What is the name of the environment in Python that write your programs and then test them out? answer choices a. Shell b. Window c. IDLE d. CLI

c. IDLE

When you use a variable before it is declared you will get a? answer choices a. TypeError b. SyntaxError c. NameError d. Syntax Error

c. NameError

Which of the following is correct? answer choices a. Print(4-4) b. print("4-4") c. print(4-4) d. Print("4-4")

c. print(4-4)

To perform multiplication in Python we use the answer choices a. + b. - c. / d. *

d. *

What would print (10 + 16) produce? answer choices a. 20 b. 22 c. 24 d. 26

d. 26

x = 5 y = 6 print(x*y) The code above displays the following: answer choices a. 11 b. x*y c. Syntax Error d. 30

d. 30

Characters that allows Python to use reserved symbol in strings answer choices a. NameError b. SyntaxError c. TypeError d. Escape Characters

d. Escape Characters

.title( ) makes all your text? answer choices a. Snake Case b. Lower Case c. Capitalized d. Initial Caps

d. Initial Caps

.upper(), .lower(), .title() are all types of answer choices a. Variables b. Integers c. Floats d. Methods

d. Methods

You need to use a ____ symbol in a string.

quote


संबंधित स्टडी सेट्स

UNIT 13: Property Insurance Basics

View Set

Hazard Mitigation Article - CoBRA

View Set

Unit 8: E-Commerce and Social Media

View Set

Ch. 4 Practice Quiz: Multiple Choice

View Set

APUSH 1st semester exam (memorize answers)

View Set

Biology 3700: Exam 2 Study Set- Dr. Nicholas Blay

View Set