Home
Explore
Exams
Search for anything
Search for anything
Login
Get started
Home
Engineering
Computer Science
Programming Notes Pt. 1
Studied by 0 people
0.0
(0)
Add a rating
Learn
A personalized and smart learning plan
Practice Test
Take a test on your terms and definitions
Spaced Repetition
Scientifically backed study method
Matching Game
How quick can you match all your cards?
Flashcards
Study terms and definitions
1 / 9
Earn XP
Description and Tags
Computer Science
University/Undergrad
Add tags
10 Terms
View all (10)
Star these 10
1
What is the purpose of variables
To store values for later use
New cards
2
What are expressions? Provide an example
Code that yields a value when evaluated (20\*40, yields 800)
New cards
3
Comments
Helpful way to explain code to a reader
New cards
4
The value of a variable can be printed out via:
print(variable_name)
New cards
5
Reading input is achieved using the
input() function
New cards
6
A programmer can combine input() and int() to read in a string from the user and then convert that string to an integer by inputting
int(input())
New cards
7
strings
a sequence
New cards
8
What function can be used to find the length of a string ( and any other sequence type)
len()
New cards
9
How do we access substrings?
Use the Square brackets for slicing along with the index to obtain your substring
Ex: var1 = ‘Hello World!’
var2=”Python Programming”
print( “var1\[0\]:" , var1\[0\]
New cards
10
Python strings are “immutable” meaning
They cannot be changed after they are created
New cards
Explore top notes
Chapter 8: Investigation and Evidence Collection
Note
Studied by 16 people
838 days ago
5.0
(1)
Preview
Chemical Formulas and Nomenclature
Note
Studied by 31 people
866 days ago
5.0
(3)
Preview
Respiration in Plants
Note
Studied by 7 people
854 days ago
5.0
(1)
Preview
COMPLETE REVIEW: HISTORICAL PERIOD 9
Note
Studied by 7 people
881 days ago
5.0
(1)
Preview
Unit 7: Quantum, Atomic, and Nuclear Physics
Note
Studied by 313 people
321 days ago
5.0
(2)
Preview
Lab Safety Video #1: Accident at Jefferson High
Note
Studied by 7 people
109 days ago
5.0
(4)
Preview
AP World History - Ultimate Guide
Note
Studied by 172 people
533 days ago
5.0
(1)
Preview
Inversionsfrage
Note
Studied by 14 people
61 days ago
5.0
(1)
Preview
Explore top flashcards
Hematological Problems
Flashcard (116)
Studied by 2 people
97 days ago
5.0
(1)
Preview
Earth Science Test 7
Flashcard (25)
Studied by 7 people
822 days ago
4.5
(2)
Preview
Ap Government Chapter 7-9
Flashcard (71)
Studied by 1 person
697 days ago
5.0
(1)
Preview
Cognitive development test review
Flashcard (48)
Studied by 7 people
105 days ago
5.0
(1)
Preview
Plant Science Exam 3
Flashcard (103)
Studied by 40 people
485 days ago
5.0
(1)
Preview
SBI3U Genetics
Flashcard (83)
Studied by 2 people
649 days ago
5.0
(2)
Preview
unit 1 and 2 bio theory
Flashcard (269)
Studied by 8 people
590 days ago
5.0
(3)
Preview
F2 Vocab 2.3 (la routine)
Flashcard (69)
Studied by 36 people
21 days ago
5.0
(1)
Preview