Tuesday, December 8, 2009
Electronic Voting
Sunday, November 22, 2009
Intellectual Property
- Downloading a song you don't own from a struggling independent artist (who doesn't give you explicit permission).
- Making music you own publicly available on the Internet, such as through KazAa or Limewire.
- Creating and giving away "Mix CDs" of music you like to friends
Friday, October 23, 2009
Blog 4: Python Output Homework
1. Given the following python function definition:
def combine(a, b):
result = 0
while b > 0:
result = result + a
b = b - 1
return result
a. What does combine(3,4) return?
0+a+a+a+a = 3*4 = 12
b. What does combine(6,7) return?
0+6+6+6+6+6+6+6=6*7=42
c. What does combine(3,0) return?
0 of course! It won't enter the 'while' loop is the second input isn't > 0.
d. What mathematical function does combine compute?
a*b! *gasp*
2. Given the following python function definition:
def splitup(a,b):
result = 0
while a >= b:
result = result + 1
a = a - b
return result
a. What does splitup(10,2) return?
0+1+1+1+1+1=5
b. What does splitup(8,2) return?
0+0+0+0+0=4
c. What does splitup(35,5) return?
0+1+1+1+1+1+1=6
d. What mathematical function does splitup compute
a/b *gasp*
3. Given the following python function definitions:
def strange(a):
print "Strange: a = ",a
def weird(a, b):
print "weird: a = ", a, "b = ", b
strange(a+b)
def reallyWeird(a, b):
strange(a - b)
print "reallyWeird: a = ", a, "b = ", b
strange(a+b)
def downrightOdd(a):
print "downrightOdd: a = ", a
reallyWeird(2*a, a)
What is the output of each of the following statements:
a. strange(6)
Strange: a = 6
b. weird(8, 4)
weird: a = 8 b = 4
strange: a = 12
c. reallyWeird(8, 4)
def odd(a):
result = 0
while a > 1:
a = a / 2
result = result + 1
return result
a. What does odd(2) return?
1
EXTRA CREDIT: What mathematical function does odd compute?
Wednesday, September 30, 2009
Blog Assignment 3: Maths
For any outside readers this is a homework assignment, I'm not showing off here.
- Convert the following binary numbers to both hexadecimal (base-16) and decimal (base-10)
a. Bin: 1011 Hex: B Dec: 11
b. Bin: 10101 Hex: 15 Dec: 21
c. Bin: 10010110 Hex: 96 Dec: 150
d. Bin: 1111111 Hex:7F Dec: 27 - Convert the following decimal numbers to both binary (base-2) and hexadecimal (base-16)
a. Dec: 8 Hex: 8 Bin: 1000
b. Dec: 63 Hex: 3F Bin: 111111
c. Dec: 113 Hex: 71 Bin: 1110001
d. Dec: 97 Hex: 61 Bin: 1100001 - Suppose that we want to download a 200 MB file. How long will it take on each of the following connections?
a. A modem that can download at 56 kilobits/second
(1638400 bits, so ~29257.14 seconds) 8 hours, 7 minutes, 31 seconds
b. A DSL connection that can download at 5 Megabits/second
(320 Seconds) 5 minutes 20 seconds
c. A high-speed connection that can download 10 Megabits/second
2 minutes 40 seconds - If we have an Internet connection that can upload 3 Megabits/second, and an MP3 is 60 Megabytes, how many MP3s can we upload in an hour? In a month (given a reliable connection)?
(491520 bits, 24576 bits/second, 88473600 bits/hour, divides evenly to:) 180 MP3s
Monday, September 28, 2009
Net Neutrality
Monday, September 21, 2009
List of related web pages so far.
- Here is a list of class projects, web sites, and other things I've worked on:
This Page (Lab 1)
San Francisco Homeless Resource web site (Lab 2)
Blog post about Cloud Computing (Blog 1)
My USF CS hosting (To be replaced with an index page)
HTML Test Page (Early Lab 3)
Tiny Hats - The Fashion Scourge (Lab 3, HTML Version)
CSS Test Page (Early Lab 4)
Tiny Hats - The Fashion Scourge (Lab 4, CSS Version)Blog post about Internet Neutrality (Blog 2)
Blog assignment about Maths (Blog 3)
Python files (Python Labs 1-3, Mini Lab 1-4)
Page of Python Labs (Python Labs 1-4, Image Lab I-III)
Blog Post about Python Input (Blog 4)
Blog post about Intellectual Property (Blog 5, Coming Soon)- Here are other resources related to the class:
Wednesday, September 9, 2009
Cloud Computing
What is cloud computing?
I used to think of cloud computing as a buzz word. Groups of computers such as beowulf clusters were formerly considered a "cloud" but it the modern usage is entirely different.
These days “cloud computing” refers to applications and storage being available and used through the network, rather than locally. This means that work in done online through the browser and information is saved out in servers somewhere that you could likely not find.
What are the benefits and disadvantages of cloud computing for an ordinary computer user?
The ordinary user may have trouble finding documents stored locally or collaborating, which can be easier through “the cloud.” In an extreme example, if a user’s computer explodes his documents in the cloud will be just fine!
What are the benefits and disadvantages of cloud computing for a start-up company?
Presently cloud computing for certain tasks (such as word processing) can be cheaper and easier to deploy than traditional desktop applications. The downsides are reliance on the network and having potentially sensitive documents out on the internet.
What are the social dangers of cloud computing? That is, why might people be uneasy about the whole world's documents being stored on GoogleDocs instead of on local machines?
Simply put, it’s not easy to trust a large corporation with your documents. For years users have been storing copies personally, used to having it physically sitting right next to them. The move to cloud computing is even less physical. The dangers associated are potential hackers and packet sniffers who could steal or copy documents in their entirety.
Wednesday, September 2, 2009
Monday, August 31, 2009
Second Day of Class!
http://sites.google.com/site/sfhomelessresources/
