Snake pit Can write any expression Expression has a value and type int (3) str (hi) long (3333333333333333333333333333) float (3.3) Type sometimes interacts with operators (+) ( / ) 1/3 is 0, 3 goes into 1; 0 times 1.0/3.0 is .3333333333 The differe
CSUY 1114 Lab 1:
In this lab, you will learn to:
 Install Python 3 and IDLE, if you have not already.
 Use the shell & the editor.
After you are comfortable with the interface, proceed with the following problems:
1. Program to print your name (no inpu
ANSWER KEY
cs1114 REVIEW of details test closed laptop period
python details DOES NOT COVER FUNCTIONS!
This is a sample of some of the things that you are responsible for do not believe that if you know
only the things on this test that they will get an A
selftest REVIEW NOT A COMPLETE OR THOROUGH STUDY
1 Ask the user for a float value then show her the value:
_
cosine x3
You do NOT have to convert the number into radians.
Do write the required import(s) that would be needed.
import math
def cosSqrtOfCube
QUESTIONS
cs1114 REVIEW of details test closed laptop period
python basics does NOT include functions!
This is a sample of some of the things that you are responsible for do not believe that if you know
only the things on this test that they will get an A
#1a
number = int(input("Enter the number ")
for i in range (1,number+1):
space = " " * (numberi)
print (" "*(numberi), "*"*(2*i1)," "*(numberi),sep=")
#1b
number = int(input("Enter the number ")
for i in range (1,number+1):
print ( "#" * (i1) + "%" +
#1
number = int(input("Enter your digit")
a= number%100
b= a/10
c= a%10
d= c+b
print (d)
#2
#3
x= int(input("please enter the dividend")
y= int(input("please enter the divisor")
i=0
while x>=y:
x=xy
i+=1
print (i)
#4
x= int(input("please enter the divide
#1
string = input("Enter your String here ")
string_space= " "
offset = ord("a")ord("A")
for characters in string:
if characters >= "a" and characters <= "z":
string_space+= chr(ord(characters)offset)
elif characters >= "A" and characters <= "Z":
string
import math
a_value = float(input("Enter value a ")
b_value = float(input("Enter value b ")
c_value = float(input("enter value c ")
decider = (b_value*2)(4*a_value*c_value)
if decider< 0:
print("real solutions")
elif decider = 0:
one_solution = round(b_
side_1 = float (input("Enter side 1, smallest side ")
side_2 = float (input("Enter side 2, medium side ")
side_3 = float (input("Enter side 3, biggest side ")
if side_1 = side_2 = side_3:
print ("The triangle is equilateral")
if side_1 = side_2 and side_3
first_item = float(input("Please enter price of first item ")
second_item = float(input("Please enter price of second item ")
club_card = str(input ("Have a store card? (Y/N) ")
tax = float(input("Enter the tax rate ")
print ("Base Price = ",first_item +
import math
import turtle
side_1 = float (input("Enter side 1 here ")
side_2 = float (input("Enter side 2 here ")
angle = float(input("Enter angle here ")
radians= math.radians(angle)
side_3= (side_1*2)+(side_2*2)(2*side_1*side_2)*math.cos(radians)*1/2)
day = str(input("Call started on? (Enter complete date, eg. Monday) ")
time = int(input("Time the call started (hhmm) ")
duration = int(input("Duration of the call (mins) ")
bill = "
if day =
"Monday" or "Tuesday" or "Wednesday" or "Thursday" or "Friday":
weight = float(input("please enter weight in kilograms ")
height = float(input("please enter height in meters" )
BMI= weight/(height*2)
if BMI < 18.5:
print ("you are underweight")
elif BMI >= 18.5 and BMI<= 24.9:
print ("you are normal")
elif BMI >= 25 a
selftest REVIEW NOT A COMPLETE OR THOROUGH STUDY
1 Ask the user for a float value then show her the value:
_
cosine x3
You do NOT have to convert the number into radians.
Do write the required import(s) that would be needed.
2 What! you didn't write at l
reec06 review for Test ONE Fall09
Print your name legibly:
circle your last name
Kletenik
Gallagher
Sign:
PolyID:
(circle your prof's name)
REVISED
For the following questions, use these variable definitions.
a = 4444
b = 2
c = 11.11
d = "hello"
What is
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework # 10
Due _Nov.23rd_11:55pm_
Submission instruction:

Submit one .py file which contains your answers to all the questions.

Unless specified
NYU, Polytechnic School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework #2
Due by Monday, 9/28, 11:55pm
Submission instructions:
1. You should submit your homework in the NYU Classes system.
2. For this assignm
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework # 7
Due _Nov. 2nd 11:55pm_
Submission instructions:
1. You should submit your homework in the NYU Classes system.
2. Put your code in 3 .py fil
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework # 8
Due _Nov. 9nd 11:55pm_
Submission instructions:
1. You should submit your homework in the NYU Classes system.
2. Please submit one .py file
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework #5
Due by Monday, 10/26, 11:55pm
Submission instructions:
1. You should submit your homework i
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework # 8.3
You may hand this in either with HW 8 OR with HW 9, marked as hw8q3.py
Submission instructions:
1. You should submit your homework in the
NYU, Tandon School of Engineering
CSUY 1114 Introduction to Programming and Problem Solving Fall 2015
Homework # 11  File I/O and Data Handling
Due: December 7th 11:55pm
Submission instructions:
Submit only ONE file: LastName_FirstName_HW11.py (US
CS 1114  Homework 4
NYU Polytechnic School of Engineering
Due by Monday, October 12, 11:55pm
Submission instructions:
You should submit your homework to NYU Classes by the due date. You will be allowed to
submit late for one day with a 20% penalty.
Sub
1114 Lab 10
Key points for this lab:
 File I/O
 List
Part I: pencil and paper problems
Problem 1:
What would be printed by the following code? Draw the runtime stack. How do the variables
change?
def func_a(list1, var1):
var1 = 5
for i in range(len(list
reec06 review for Test ONE
Print your name legibly:
circle your last name
Sign:
PolyID:
JUST LIKE THE REAL TEST BRING ONLY A WRITING UTENSIL,
YOUR ID, AND YOUR BRAIN TO THE TEST.
For the following questions, use these variable definitions.
a = 4444
b = 2
Do not sign this page.
It will be removed.
CS1114
Fall 2014
SECOND Test
NOTE: There are LONGER problems at the end of the test and a couple of functions to define before that.
A good strategy would be to skip any questions you cannot do quickly
to get to
answer key
ANSWER KEY
page 1 of 6 pages (counting the cover sheet)
1. (3 pts) The list type is an iterable object.
(circle your answer)
TRUE
FALSE
WHAT IS THE OUTPUT questions write your answer to the right of the question
If the code won't compile, write