B Intro to IT unit 5 variables and data types assignment

¡Supera tus tareas y exámenes ahora con Quizwiz!

is a group of scalar or individual values that are stored in one entity. -scalar values -array -user defined type -abstract data type

array

A variable that can be used with moveable decimal points is a(n) ___________ data type. -alphanumeric string -dictionary -character -floating point number

floating point number

Use the drop-down menu to correctly complete these sentences about the five standard Python data types. are sets of data separated by a comma between two parenthesis ( ). -lists -tuples -numbers -strings

tuples

is a data type that is assigned a true or false value by a programmer. -scalar values -array -user defined type -abstract data type

user defined type

Which of these are correctly formatted Python lists? Check all that apply. A-list1=(race, cars, trucks, bikes) B-list2=['computer science', 'math', 'psychology'] C-list3=["Programming 101", "Intro to Python"] D-list4=('summer', 'fall', 'winter', 'spring') E-list5=[52, 24, 71, 72, 56]

B-list2=['computer science', 'math', 'psychology'] C-list3=["Programming 101", "Intro to Python"] E-list5=[52, 24, 71, 72, 56]

is a data type that can be assigned multiple values. -scalar values -array -user defined type -abstract data type

abstract data type

A variable that can hold positive or negative whole-number values is a(n) ______________ data type. -global -character -integer -Boolean

integer

Use the drop-down menu to correctly complete these sentences about the five standard Python data types. are sets of data separated by a comma between two brackets [ ]. -numbers -tuples -lists -strings

lists

Use the drop-down menu to correctly complete these sentences about the five standard Python data types. are numeric values in Python data types. -numbers -strings -lists -tuples

numbers

are single numbers or values, which may include integers, floating-point decimals, or strings of characters. -scalar values -array -user defined type -abstract data type

scalar values

Use the drop-down menu to correctly complete these sentences about the five standard Python data types. are connected sets of characters separated by quotation marks " ". -numbers -lists -strings -tuples

strings

A variable that is used in programming and can hold a true or false value is a(n) ________________ data type. -global -Boolean -character -integer

Boolean

A variable that can hold a mixed sequence of letters and numbers is a(n) _________________ data. -alphanumeric string -Boolean -floating point number -local

alphanumeric string

Use the drop-down menu to correctly complete these sentences about the five standard Python data types. is a large and changeable list that can contain any number of Python objects. -string -tuple -dictionary -number

dictionary

Which of these are characteristics of a Python data type? Check all that apply. A-A Python data type is weakly typed. B- Python data type can have numeric values. C-A Python data type can be shown by keys and values within brackets [ ]. D-A Python data type must be stated before it can be used in a program. E-A Python data type can be a string, a list, or a tuple with items that can be repeated using the asterisk ( * ). F-A Python data type can be a dictionary that can be updated, changed, or removed. G-A Python data type cannot have connecting sets of characters separated by commas.

A-A Python data type is weakly typed. B- Python data type can have numeric values. C-A Python data type can be shown by keys and values within brackets [ ]. E-A Python data type can be a string, a list, or a tuple with items that can be repeated using the asterisk ( * ). F-A Python data type can be a dictionary that can be updated, changed, or removed.

Which of the following are characteristics of global variables? Check all that apply. A-They are accessible from anywhere in the program. B-They are accessible only in specific regions of a program. C-They are accessible only within a declared function. D-They are accessible during the entire time the program is running.

A-They are accessible from anywhere in the program. D-They are accessible during the entire time the program is running.

Which of these are characteristics of variables? Check all that apply. A-Variables can be local or global. B-Variables cannot be changed. C-Variables have keys and values within brackets [ ]. D-Variables have connected sets of characters. E-Variables have names, extents, and scopes.

A-Variables can be local or global. E-Variables have names, extents, and scopes.

Which of these are correctly formatted Python dictionaries? Check all that apply. A-dict = {'Name': 'Matthew', 'Age': 14, 'School': 'ABC School'}; B-dict = ('Name': 'Mary', 'Age': 13, 'School': 'XYZ School') C-dict = ["Programming Basics", "Introduction to Python"] D-dict = {'season': 'fall', 'weather': 'cool'}; E-dict = '['laptop', 'computer', 'hard drive']

A-dict = {'Name': 'Matthew', 'Age': 14, 'School': 'ABC School'}; D-dict = {'season': 'fall', 'weather': 'cool'};

Which of these are correctly formatted Python tuples? Check all that apply. A-tup1=('computer science', 'math', 'psychology') B-list1=["final", "complete", "finish"] C-tup2="Programming 101", "Intro to Python" D-tup3=["MacBook", "Dell", "IBM"] E-tup4=('laptop', 'computer', 'hard drive')

A-tup1=('computer science', 'math', 'psychology') C-tup2="Programming 101", "Intro to Python" E-tup4=('laptop', 'computer', 'hard drive')


Conjuntos de estudio relacionados

Cultural Anth Midterm Part 1 (quizzes 1-4)

View Set