CSCA08H3 Lecture Notes - Lecture 3: Type System, Mendelian Inheritance

62 views9 pages
30 Oct 2015
School
Course
Professor

Document Summary

Convert these integers to a binary representation: 2, 10, 21, 27, 105, 129, 360, 496, 1729. Convert these binary representations to an integer: 0, 1, 11, 1001, 11011, 11111, 100000, 1010101, 10011010010. Trace through this code using the memory model. What is printed out: my_var = 2. You may also find the function split() to be helpful (try typing help(split()) in the shell window) Python is a dynamically typed language, which means you don"t have to assign a. Question # 5 specific type to a variable. How does this compare to a language, like java, that requires variables to be of int x = 5. Give an example of a computer program being stupid (meaning it fails to understand an instruction that seems to be obvious to a human). Java functions: str_num_integrator(int a, string b) str_num_integrator(float a, string b) This one is almost purely logical, almost no coding required.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents