Computer Science > EXAM > CS 1101 Programming Fundamentals - Term 4, 2018-2019. | Score 27.00/30.00 (All)

CS 1101 Programming Fundamentals - Term 4, 2018-2019. | Score 27.00/30.00

Document Content and Description Below

CS 1101 Programming Fundamentals - Term 4, 2018-2019. | Score 27.00/30.00 Match concepts with their denition. An error in a program. bug The process of nding and removing any of the three kinds o... f programming errors. debugging Any one of the languages that people have designed for specic purposes, such as representing mathematical ideas or computer programs; all programming languages are this kind of languages. formal language A programming language like Python that is designed to be easy for humans to read and write. high-level language A program that reads another program and executes it. interpreter A programming language that is designed to be easy for a computer to execute; also called machine language or assembly language. low-level language Any one of the languages that people speak that evolved naturally. natural language To examine a program and analyse the syntactic structure. parse A property of a program that can run on more than one kind of computer. portability An instruction that causes the Python interpreter to display a value on the screen. print statement The process of formulating a problem, nding a solution, and expressing the solution. problem solving a sequence of instructions that species to a computer actions and computations to be performed. program A program stored in a le (usually one that will be interpreted). script Question 2 Correct Mark 1.00 out of 1.00 Question 3 Correct Mark 1.00 out of 1.00 One of the basic elements of the syntactic structure of a program, analogous to a word in a natural language. token The structure of a program. syntax Given a Python dictionary d and a value v, it is ecient to nd the corresponding key: d[k] = v. Select one: True False Which one of the following Python expressions generates a syntax error? Select one: a. 8 ^ 2 b. 8 ** 2 c. 8 +- 2 d. 8 += 2 e. 8 -+ 2 Your answer is correct. Question 4 Correct Mark 1.00 out of 1.00 Question 5 Incorrect Mark 0.00 out of 1.00 What is the output of the Python code below? my_list = [3, 2, 1] print(my_list.sort()) Select one: a. 0 b. {1, 2, 3} c. None d. syntax error e. [1, 2, 3] Your answer is correct. What is Python’s response to the command: type(0.123) Select one: a. <class 'oat'> b. <class 'bool'> c. SyntaxError: invalid syntax d. <class 'int'> e. <class 'str'> Your answer is incorrect. Question 6 Correct Mark 1.00 out of 1.00 Question 7 Incorrect Mark 0.00 out of 1.00 Question 8 Correct Mark 1.00 out of 1.00 Assume that d is a Python dictionary. What does the following Python code produce? result = dict() for key in d: val = d[key] if val not in inverse: result[val] = [key] else: result[val].append(key) Select one: a. a histogram b. an inverted dictionary c. a list of tuples d. a lookup e. a reverse lookup [Show More]

Last updated: 4 months ago

Preview 4 out of 16 pages

Buy Now

Instant download

We Accept:

We Accept
loader

Loading document previews ...

Buy this document to get the full access instantly

Instant Download Access after purchase

Buy Now

Instant download

We Accept:

We Accept

Also available in bundle (1)

CS 1101 Programming Fundamentals. all terms questions and answers, practice questions with correct answers and project.

CS 1101 Programming Fundamentals. all terms questions and answers, practice questions with correct answers and project. the right A grade materials to pass.

By Professor Lynne 4 years ago

$11

13  

Reviews( 0 )

$9.00

Buy Now

We Accept:

We Accept

Instant download

Can't find what you want? Try our AI powered Search

108
0

Document information


Connected school, study & course


About the document


Uploaded On

Jun 07, 2021

Number of pages

16

Written in

Seller


seller-icon
Professor Lynne

Member since 4 years

369 Documents Sold

Reviews Received
34
13
4
0
4
Additional information

This document has been written for:

Uploaded

Jun 07, 2021

Downloads

 0

Views

 108

More From Professor Lynne

View all Professor Lynne's documents »

Recommended For You

Get more on EXAM »

$9.00
What is Scholarfriends

In Scholarfriends, a student can earn by offering help to other student. Students can help other students with materials by upploading their notes and earn money.

We are here to help

We're available through e-mail, Twitter, Facebook, and live chat.
 FAQ
 Questions? Leave a message!

Follow us on
 Twitter

Copyright © Scholarfriends · High quality services·