Geschreven door studenten die geslaagd zijn Direct beschikbaar na je betaling Online lezen of als PDF Verkeerd document? Gratis ruilen 4,6 TrustPilot
logo-home
Tentamen (uitwerkingen)

CSCI 1170 FINAL EXAM QUESTIONS ANSWERED CORRECTLY LATEST UPDATE 2026

Beoordeling
-
Verkocht
-
Pagina's
7
Cijfer
A+
Geüpload op
29-05-2026
Geschreven in
2025/2026

CSCI 1170 FINAL EXAM QUESTIONS ANSWERED CORRECTLY LATEST UPDATE 2026 The Python interpreter is a program that can read Python programming statements and execute them T or F - Answers T A Python variable name cannot begin with a digit T or F - Answers T In Python math expressions are evaluated from left to right, no matter what the operators are T or F - Answers F The % symbol is the percentage operator and is also known as the precedence operator T or F - Answers F Statements in the loop body of a WHILE statement will NOT be executed if the predicate initially evaluates to FALSE T or F - Answers T Converting programming instructions to machine instructions is a function of - Answers compilers A bit is - Answers an element of a byte and can be "off" or "on" A cursor is a - Answers symbol that shows where the next character will be entered on the screen The part of a record that is used to store individual facts or data items is called - Answers a field Which of the following is NOT true of comments in Python a) they can begin anywhere on a line b) they are optional text included by the programmer c) they translate into one machine language instruction d) they are preceded by the symbol # - Answers c Evaluating the expression [3 // 2 - 3.0 / 2] yields the value - Answers -.5 Which of the following is NOT legal syntax of a floating point value a) 3.1415 b) 31415 c) 31415. d) 3.1415E-4 - Answers b The predicate of a WHILE is - Answers evaluated before each iteration of the loop The ____________ function reads a piece of data that has been entered at the keyboard and returns that piece of data, as a string, back to the program - Answers input Memory is said to be ______________ if data and programs are erased when the power to a computer is turned off - Answers volatile The line continuation character is a - Answers Which mathematical operator is used to raise 5 to the second power in Python - Answers ** In Python names of variables and names of functions are all generically known as - Answers identifiers The form of a program that we as programmers modify with an editor is called the _____________ program and might be stored in the file - Answers source After execution of the statement [ sold = 256.752 ] the variable [ sold ] will reference the numeric literal value as a(n) __________ data type - Answers float After execution of the statement [ price = int(68.549) ] the variable [ price ] will reference the value - Answers 68 Where does a computer store a program and the data that the program is working with while the program is running - Answers primary storage Exactly 2^20 bytes is called a a) Terabyte b) Kilobyte c) Gigabyte d) None of these - Answers d What type of error is it when Reeborg performs the wrong task - Answers logic error UNIX command to list the names of of all files in the current directory - Answers ls UNIX command to remove the file - Answers rm UNIX command to change current directory from home to OLA - Answers cd OLA UNIX command to make a copy of the file called - Answers cp UNIX command to create a directory called unixstuff - Answers mkdir unixstuff UNIX command to display contents of onto the screen a page at a time - Answers more A system or language that distinguishes between upper and lowercase letters is said to be ____________ - Answers case sensitive What are three types of program maintenance - Answers corrective adaptive perfective What will the following statements cause the computer to print x = 99 y = 444 z = x x = y y = z print(x) print(y) - Answers 444 99 The main reason for using secondary storage is to hold data for long periods of time, even when the power supply to the computer is turned off T or F - Answers T According to the behavior of integer division in Python when an integer is divided by an integer the result will be a float T or F - Answers F Python allows programmers to break a statement into multiple lines T or F - Answers T In Python the assignment operator and the equality operator are represented the same way T or F - Answers F Reducing duplications of code is one of the advantages of using a loop structure T or F - Answers T Assuming [number] has an integer value the clause [if not (number9):] is equivalent to the clause [if (number10): ] T or F - Answers F Python allows you to compare strings T or F - Answers T In Python an identifier cannot start with a digit T or F - Answers T Semantics is the term used when we refer to the meaning of a statement T or F - Answers T Both of the following [for] classes would generate the same number of loop iterations: for num in range(4): for num in range(1,5): T or F - Answers T Which would be a poor choice for a sentinel value a) 999 for voter_age b) 1 for test_score c) 13 for birthday_month d) 75 for car_speed e) b and d - Answers e Which assignment statement could be used to store the symbol @ into the variable at_sign a) at_sign = "@" b) at_sign = @ c) at_sign = '@' d) a and c e) a b and c - Answers d How many bits are in one byte - Answers 8 What values of num will print given the code fragment for num in range(2,9,2) print(num) - Answers 2 4 6 8 What is the output of the following program fragment x = 25.628499 print('$',format(x,'6.2f'),'7d') - Answers $--25.63-7d What is the output of the following program fragment alpha = 20 beta = 100 print( alpha, beta, format(alpha/beta,'.1%') - Answers 20-100-20.0% How many lines of output are produced by the following program fragment n = 5 print("Item A", "Item BnItem C", "Item D", end="") candidate = "Item E" print(n, candidate) candidate = "ItemnF" print(candidate,n,sep='*') - Answers 3 If the variables i ,j, and k contain the integer values 10, 3, 20 (respectively), what is the value of the following boolean expression ( i 4 and ( j == 5 or i = k) ) - Answers False If [flag] contains a boolean value, which of the following boolean expressions always evaluates to the value [False] a) flag and flag b) flag or flag c) flag and not flag d) flag or not flag e) b and d - Answers c Using De Morgan's Law, negating the expression (ij) and (k==x) yields - Answers (i=j) or (k!=x) Which of the following Python statements could be used to read a word from std input into the variable [term] a) cin term b) term = input('Enter word: ') c) read(term) d) input(term) e) term = int(read('word')) - Answers b The part of a record that is used to store individual facts or data items is called - Answers a field What is the value of count after control exits the following loop alpha = 0 count = 10 while count = 145: alpha = alpha + 7 count += 1 - Answers 146 What is not an example of an augmented assignment operator a) *= b) /= c) **= d) = e) %= - Answers d The first input operation is called the _______________ and its purpose is to get the first input value that will be tested by the predicate of the validation loop - Answers priming read 5 + 5 // 10 = ? - Answers 5 23 % 4 = ? - Answers 3 -2.5 = 2.5 ? - Answers True ( 2 * 12.5 ) / 2 = ? - Answers 12.5 - ( -4.1) = ? - Answers 4.1 2 ** 10 = ? - Answers 1024 "xy" "abcd" = ? - Answers True 'hi' == "hi" - Answers True Write a Python assignment statement that assigns the variable y the result of evaluating the mathematical expression [9n^2 +5n] / [n-2.5] - Answers y = (9 * (n ** 2) + 5 * n) / (n -2.5) Write a Python statement that triples the value of the variable num - Answers num = num *3 Briefly what is a short-circuit - Answers [Edit] Complete the following truth table r h r and h r or h ------ ------- ------------- ----------

Meer zien Lees minder
Instelling
CSCI 1170
Vak
CSCI 1170

Voorbeeld van de inhoud

CSCI 1170 FINAL EXAM QUESTIONS ANSWERED CORRECTLY LATEST UPDATE 2026

The Python interpreter is a program that can read Python programming statements and execute them

T or F - Answers T
A Python variable name cannot begin with a digit

T or F - Answers T
In Python math expressions are evaluated from left to right, no matter what the operators are

T or F - Answers F
The % symbol is the percentage operator and is also known as the precedence operator

T or F - Answers F
Statements in the loop body of a WHILE statement will NOT be executed if the predicate initially
evaluates to FALSE

T or F - Answers T
Converting programming instructions to machine instructions is a function of - Answers compilers
A bit is - Answers an element of a byte and can be "off" or "on"
A cursor is a - Answers symbol that shows where the next character will be entered on the screen
The part of a record that is used to store individual facts or data items is called - Answers a field
Which of the following is NOT true of comments in Python

a) they can begin anywhere on a line
b) they are optional text included by the programmer
c) they translate into one machine language instruction
d) they are preceded by the symbol # - Answers c
Evaluating the expression [3 // 2 - 3.] yields the value - Answers -.5
Which of the following is NOT legal syntax of a floating point value

a) 3.1415
b) 31415
c) 31415.
d) 3.1415E-4 - Answers b
The predicate of a WHILE is - Answers evaluated before each iteration of the loop
The ____________ function reads a piece of data that has been entered at the keyboard and returns
that piece of data, as a string, back to the program - Answers input
Memory is said to be ______________ if data and programs are erased when the power to a
computer is turned off - Answers volatile
The line continuation character is a - Answers \
Which mathematical operator is used to raise 5 to the second power in Python - Answers **
In Python names of variables and names of functions are all generically known as - Answers
identifiers
The form of a program that we as programmers modify with an editor is called the _____________
program and might be stored in the file hurdles17.py - Answers source
After execution of the statement [ sold = 256.752 ] the variable [ sold ] will reference the numeric
literal value as a(n) __________ data type - Answers float
After execution of the statement [ price = int(68.549) ] the variable [ price ] will reference the value -
Answers 68
Where does a computer store a program and the data that the program is working with while the
program is running - Answers primary storage
Exactly 2^20 bytes is called a

a) Terabyte
b) Kilobyte
c) Gigabyte

, d) None of these - Answers d
What type of error is it when Reeborg performs the wrong task - Answers logic error
UNIX command to list the names of of all files in the current directory - Answers ls
UNIX command to remove the file boxes.wld - Answers rm boxes.wld
UNIX command to change current directory from home to OLA - Answers cd OLA
UNIX command to make a copy of the file hurdles.py called backup.py - Answers cp hurdles.py
backup.py
UNIX command to create a directory called unixstuff - Answers mkdir unixstuff
UNIX command to display contents of hurdles.py onto the screen a page at a time - Answers more
hurdles.py
A system or language that distinguishes between upper and lowercase letters is said to be
____________ - Answers case sensitive
What are three types of program maintenance - Answers corrective adaptive perfective
What will the following statements cause the computer to print

x = 99
y = 444

z=x
x=y
y=z

print(x)
print(y) - Answers 444
99
The main reason for using secondary storage is to hold data for long periods of time, even when the
power supply to the computer is turned off

T or F - Answers T
According to the behavior of integer division in Python when an integer is divided by an integer the
result will be a float

T or F - Answers F
Python allows programmers to break a statement into multiple lines

T or F - Answers T
In Python the assignment operator and the equality operator are represented the same way

T or F - Answers F
Reducing duplications of code is one of the advantages of using a loop structure

T or F - Answers T
Assuming [number] has an integer value the clause [if not (number>9):] is equivalent to the clause [if
(number<10): ]

T or F - Answers F
Python allows you to compare strings

T or F - Answers T
In Python an identifier cannot start with a digit

T or F - Answers T
Semantics is the term used when we refer to the meaning of a statement

T or F - Answers T
Both of the following [for] classes would generate the same number of loop iterations:
for num in range(4):

Geschreven voor

Instelling
CSCI 1170
Vak
CSCI 1170

Documentinformatie

Geüpload op
29 mei 2026
Aantal pagina's
7
Geschreven in
2025/2026
Type
Tentamen (uitwerkingen)
Bevat
Vragen en antwoorden

Onderwerpen

€10,15
Krijg toegang tot het volledige document:

Verkeerd document? Gratis ruilen Binnen 14 dagen na aankoop en voor het downloaden kun je een ander document kiezen. Je kunt het bedrag gewoon opnieuw besteden.
Geschreven door studenten die geslaagd zijn
Direct beschikbaar na je betaling
Online lezen of als PDF

Maak kennis met de verkoper

Seller avatar
De reputatie van een verkoper is gebaseerd op het aantal documenten dat iemand tegen betaling verkocht heeft en de beoordelingen die voor die items ontvangen zijn. Er zijn drie niveau’s te onderscheiden: brons, zilver en goud. Hoe beter de reputatie, hoe meer de kwaliteit van zijn of haar werk te vertrouwen is.
joshuawesonga22 Liberty University
Volgen Je moet ingelogd zijn om studenten of vakken te kunnen volgen
Verkocht
100
Lid sinds
1 jaar
Aantal volgers
1
Documenten
14186
Laatst verkocht
1 dag geleden
Tutor Wes

Hi there! I'm Tutor Wes, a dedicated tutor with a passion for sharing knowledge and helping others succeed academically. All my notes are carefully organized, detailed, and easy to understand. Whether you're preparing for exams, catching up on lectures, or looking for clear summaries, you'll find useful study materials here. Let’s succeed together!

3,9

9 beoordelingen

5
4
4
1
3
3
2
1
1
0

Recent door jou bekeken

Waarom studenten kiezen voor Stuvia

Gemaakt door medestudenten, geverifieerd door reviews

Kwaliteit die je kunt vertrouwen: geschreven door studenten die slaagden en beoordeeld door anderen die dit document gebruikten.

Niet tevreden? Kies een ander document

Geen zorgen! Je kunt voor hetzelfde geld direct een ander document kiezen dat beter past bij wat je zoekt.

Betaal zoals je wilt, start meteen met leren

Geen abonnement, geen verplichtingen. Betaal zoals je gewend bent via iDeal of creditcard en download je PDF-document meteen.

Student with book image

“Gekocht, gedownload en geslaagd. Zo makkelijk kan het dus zijn.”

Alisha Student

Bezig met je bronvermelding?

Maak nauwkeurige citaten in APA, MLA en Harvard met onze gratis bronnengenerator.

Bezig met je bronvermelding?

Veelgestelde vragen