Where are we going Where have we been
Where are we going ? Where have we been? Twenty years of Computer Science and Programming Owen Astrachan http: //www. cs. duke. edu/~ola Reflections/Projections 2004 1
I teaching programming Reflections/Projections 2004 2
What is Computer Science? What is the central core of the subject? What is it that distinguishes it from the separate subjects with which it is related? What is the linking thread which gathers these disparate branches into a single discipline? My answer to these questions is simple --- it is the art of programming a computer. Reflections/Projections 2004 3
Programming != Computer Science It is the interplay between such fundamental challenges and the human condition that makes computer science so interesting. The results from even the most esoteric computer science research programs often have widespread practical impact. Computer security depends upon the innovations in mathematics. Your Google search for a friend depends on state-of-theart distributed computing systems, algorithms, and artificial intelligence. http: //www. post-gazette. com/pg/pp/04186/341012. stm Reflections/Projections 2004 4
Don’t know much about history We are doomed if we don’t pay attention Reflections/Projections 2004 5
11/08/77 Reflections/Projections 2004 6
17 Nov 75 Not needed Can be tightened considerably Reflections/Projections 2004 7
Jim Gray (Turing 1998) l Bubble sort is a good argument for analyzing algorithm performance. It is a perfectly correct algorithm. But it's performance is among the worst imaginable. So, it crisply shows the difference between correct algorithms and good algorithms. (italics mine) Reflections/Projections 2004 8
Brian Reid (Hopper Award 1982) Feah. I love bubble sort, and I grow weary of people who have nothing better to do than to preach about it. Universities are good places to keep such people, so that they don't scare the general public. Reflections/Projections 2004 (continued) 9
Brian Reid (Hopper 1982) I am quite capable of squaring N with or without a calculator, and I know how long my sorts will bubble. I can type every form of bubble sort into a text editor from memory. If I am writing some quick code and I need a sort quick, as opposed to a quick sort, I just type in the bubble sort as if it were a statement. I'm done with it before I could look up the data type of the third argument to the quicksort library. I have a dual-processor 1. 2 GHz Powermac and it sneers at your N squared for most interesting values of N. And my source code is smaller than yours. Reflections/Projections 2004 10
Niklaus Wirth (Turing award 1984) I share your view that Bubble Sort has hardly any merits. I think that it is so often mentioned, because it illustrates quite well the principle of sorting by exchanging. I think BS is popular, because it fits well into a systematic development of sorting algorithms. But it plays no role in actual applications. Quite in contrast to C, also without merit (and its derivative Java), among programming codes. Reflections/Projections 2004 11
Past, Present, Future Reflections/Projections 2004 12
Learned Hand “the First Amendment presupposes that right conclusions are more likely to be gathered out of a multitude of tongues, than through any kind of authoritative selection. To many this is, and always will be, folly; but we have staked upon it our all. ” Reflections/Projections 2004 13
Cause for comfort or concern? Source: CRA Reflections/Projections 2004 14
Reflections/Projections 2004 15
What is CS? Why study it? “It's hard for voice over Internet Protocol or e-commerce to compete with finding the age of the universe, ” Peter Lee, Associate Dean/Professor CMU l We should compete, we cannot compete, we should join Ø What’s the right strategy? Reflections/Projections 2004 16
Reflections/Projections 2004 17
Who's going to College? Reflections/Projections 2004 18
Who's going to College? Reflections/Projections 2004 19
Who's going to College? Reflections/Projections 2004 20
1984 Reflections/Projections 2004 21
Richard Stallman’s quest l In January 1984 I quit my job at MIT and began writing GNU software. Leaving MIT was necessary so that MIT would not be able to interfere with distributing GNU as free software. If I had remained on the staff, MIT could have claimed to own the work, and could have imposed their own distribution terms, …. I had no intention of doing a large amount of work only to see it become useless for its intended purpose: creating a new software-sharing community. Reflections/Projections 2004 22
From software to politics? l Help change the world Reflections/Projections 2004 23
Teaching Compsci in 1984 l l l 64 K memory, 128 K extended 8 -bit, 1 Mhz 6502 processor 5 Mb drive: $3500 UCSD Pascal: >$100 Owen's machine: $3000 $677. 80 in 1984 has $1200 "purchase power" in 2003 l http: //eh. net/hmit/ppowerusd/ Reflections/Projections 2004 24
Typical machine in 2004? l l l Reflections/Projections 2004 1 Gb memory 3+ GHz, 32 -bit chip Ø Cache, … 160 Gb disk Lots of free resources Ø Good academic pricing Under $1000 25
What has changed in 20 years? l Machines Ø Characteristics and Availability l Internet Ø Availability, IM, web, Google, … l Students Ø Comfort with technology, Expectations Reflections/Projections 2004 26
The more things change…? Assume I took your first course(s) in 1984 and understood the concepts so completely that I could still get a 100 on the final from 1984 if I took it today (e. g. , I've been in a cryogenic chamber). How would I do on the 2004 final exam? Reflections/Projections 2004 27
What has changed in Physics? "You'd get a 100 plus or minus sigma. Intro classical physics hasn't really changed that much over the last 100 years. In graduate level e. g. E&M or quantum classes I think ditto, although sigma would be bigger (and might depend more on the instructor variation than on any real variation in the material). The main difference is, I think, that your chances of GETTING 100 now would be much higher. " Rob Brown, Poohbah of Physics Instruction Reflections/Projections 2004 28
What has changed in Biology? "The basic principles and concepts of biology haven't changed much in 20 years. What has changed relates to specific content, and in this arena the changes have been enormous. 20 years ago, we barely knew how to sequence DNA; today information of this kind has had a major impact on just about every topic in the biological sciences. Thus, some questions on an exam today would address topics that would be completely unfamiliar to a 1984 time-traveller. " Greg Wray, Director of Undergraduate Studies, Biology Reflections/Projections 2004 29
What hasn't changed in Biology? "How many electrons shift during photosynthesis? Which protein works with myosin? etc. Who, how many, what, and where but never any why questions. High school biology is driven by the advanced exams. College biology is driven by the MCATS. Many still see biology as a content driven field of thought. OK, I'm a crank. " Sherryl Broverman, Department of Biology Senior Research Fellow - Health Inequalities Program Reflections/Projections 2004 30
What has changed in Economics? "… we now cover material that was only introduced in an advanced or intermediate course in 1984. In 1984 we spent the bulk of the time dealing with the Keynesian model and virtually no dialogue about supply side policies. Now the Keynesian stuff is a small subset of a much broader exposure to Aggregate demand supply… Also there is more international coverage now - as opposed to 20 years ago for obvious reasons. " Lori Leachman, Director of Undergraduate Studies, Economics Reflections/Projections 2004 31
What has changed in Calculus? We have two varieties of calculus courses, the lab courses and the traditional. . . The latter two have not changed significantly in decades, and I think that a student who fared well on the 1984 exam in those courses would do well today, and vice versa. [In the lab courses] You would ace about half the exam. The other half would be unfamiliar to you. For example, you would probably not know how to answer a problem on modeling a set of data, creating an approximation using Euler's method, interpreting derivatives in the context of applications in other fields, or giving explanations of ideas … Reflections/Projections 2004 Lewis Blake, Supervisor of First-year Instruction 32
Changes in Computer Science? Reflections/Projections 2004 33
Changing CS? Rock, Hard place l If Computer Science has changed drastically is it to keep up with fads and stylistic changes or because of fundamental changes in the discipline? l Are we leveraging the technological and intellectual resources at our disposal l If we haven’t changed, is it because of a solid bedrock of principles that endures? Or because we’re lazy, good-for-nothing, … Reflections/Projections 2004 34
1984, AP Computer Science, Q 1 l Write a program to read eight integers from the terminal, display them in reverse order, and display the number of negative integers read. For example, given the input: -4 l 3 -2 1 -18 -20 5 -7 The program should produce the output: -7 5 -20 -18 1 -2 3 -4 5 of the integers are negative Reflections/Projections 2004 35
What concepts does this test? l Reading from standard input, terminal Ø In today’s programming we don’t do this? l What is special about the number eight? Ø Why not thirty? l Fundamental programming? Ø What would today’s question be? Reflections/Projections 2004 36
1985, AP Computer Science, Q 2 Write a procedure Compact that eliminates all elements with value 0 from its argument, a list. Compact leaves the order of the other elements unchanged. For example, if list is (0, 9, 7, 0, 0, 23, 4, 0) When the procedure is called, it should be (9, 7, 23, 4) After the procedure executes. All local variables should be scalar. (declaration for Pascal record with array and count) Reflections/Projections 2004 37
Concepts and Solutions l Why the restriction to use only scalar variables? Ø Force an expected solution? Ø Punish students? Ø What is expected solution, O(n) or O(n 2) Ø What l if I make a new array? What does this look like today? (to appear) Reflections/Projections 2004 38
2004, AP Computer Science A 1 l I can’t cut/paste from the online PDF document without a password, why? Ø Who owns the copyright? Ø What about face-to-face teaching purposes? Ø What is duration of copyright? l How is the question similar to 1984 and 1985 questions? How is it different? Ø Has more than just the language changed? Ø Is a change in language warranted? Ø How often do we change? What do we change? Reflections/Projections 2004 39
A picture is worth … Reflections/Projections 2004 40
A thousand words Write class Cat that says 'meow' l Write Loud. Dog that says 'bark-bark' when Dog l says 'bark' Reflections/Projections 2004 41
What teachers are memorable? � The good, the bad, and the …? Reflections/Projections 2004 42
John Kemeny Reflections/Projections 2004 If you have a large number of unrelated ideas, you have to get quite a distance away from them to get a view of all of them, and this is the role of abstraction. If you look at each too closely you see too many details. If you get far away things may appear simpler because you can only see the large, broad outlines; you do not get lost in petty details. 43
Great Teachers Reflections/Projections 2004 44
A Survey of Introductory Courses The principal course goal is for the students to become proficient in a single programming language. To achieve the course's objective each student must write about 300 total lines of code. This coding represents about 6 different programming assignments. At least one assignment requires writing over 75 lines of code. We estimate that a student averages over 10 hours per week on the course even though the usual turnaround time is less than ½ hour. Reflections/Projections 2004 van Dam et al, 197345
Then and Now Ouchless I/O Bailey, SIGCSE 1972 All of the Fortran statements were to be introduced as the need arose within the context of a problem-solving situation—that is, a here-is-what-we-want-how-can-we -do-it approach…the overall objective of the course was to make the instruction as interesting and informative as possible. It is remarkable that the majority of students can indeed handle fairly complex I/O by the end of the first six lessons, even though they have not actually been formally taught how to do it. Reflections/Projections 2004 46
Now and Then Java IO and Testing Made Simple, Proulx and Rasala, SIGCSE 2004 We believe that the combination of the well-designed tools with well-designed abstractions presented here provide a solid foundation for introducing input processing to novice programmers. In addition to making the input from the user an integral part of student's programs, students learn from seeing and using abstractions that provide tangible and significant benefits. Reflections/Projections 2004 47
Gries on Teaching Programming “Suppose you attend a course in cabinet making. The instructor briefly shows you a saw, a plane, a hammer, and a few other tools, letting you use each one for a few minutes. He next shows you a beautifullyfinished cabinet. Finally, he tells you to design and build your own cabinet and bring him the finished product in a few weeks. You would think he was crazy!” 1974 Reflections/Projections 2004 48
Putting it all together … …we conclude that students are not given sufficient instruction in how to "put the pieces together. " Focusing explicitly on specific strategies for carrying out the coordination and integration of the goals and plans that underlie program code may help to reverse this trend. Sporher and Soloway, Novice mistakes: Are the folks wisdoms correct? Studying the Novice Programmer, 198949 Reflections/Projections 2004
Changing Data into Knowledge We provide an unjust education if we do not give every student the maximum opportunity for learning. Depending on their natural abilities, imbalance in education deprives some students of learning more than others. Those who are naturally more creative, or have better memories, or are more reflective, or are more active have different opportunities if we do not provide balance. That is unjust. James Zull: The Art of Changing the Brain Reflections/Projections 2004 50
Changing Data into Knowledge l As teachers we are on the outside, but we have great influence by the way we manipulate, mold, and enrich the information our students need. For balance, we must give equal thought to how students take ownership of that information. How it is transformed from “ours” to “theirs”? How does the learner move from receiver to producer? Reflections/Projections 2004 51
Changing the Brain Feelings affect learning What's the amygdala? ". . Emotions tend to overpower cognition, rather than the reverse" Some sensory signals get to the amygdala before we are even aware of them, signals come from concrete experiences When we want to help someone learn, we should be aware that our learner will be quickly and subconsciously monitoring the situation through her amygdala. This isn't something she decides to do. It just happens. Reflections/Projections 2004 52
What do programmers do? l What do artists do? l What do computer scientists do? l What do engineers do? l What do scientists do? l What can we do about this? Reflections/Projections 2004 53
Teaching as … English is not history and history is not science and science is not art and art is not music, and art and music are minor subjects and English, history and science major subjects, and a subject is something you 'take' and when you have taken it, you have 'had' it, and if you have 'had' it, you are immune and need not take it again. " (The Vaccination Theory of Education? ) Reflections/Projections 2004 54
Teaching as a Subversive Activity "The inquiry method is not designed to do better what older environments try to do. It works you over in entirely different ways. It activates different senses, attitudes, and perceptions; it generates a different, bolder, and more potent kind of intelligence. Thus, it will cause teachers and their tests, and their grading systems, and their curriculum to change. It will cause college admissions requirements to change. It will cause everything to change. " italics mine Reflections/Projections 2004 55
Walking Randomly to the Future � It’s the examples, stupid Reflections/Projections 2004 56
Reflections/Projections 2004 57
Christopher Alexander, OOPSLA 96 What I am proposing here is something a little bit different from that. It is a view of programming as the natural genetic infrastructure of a living world which you/we are capable of creating, managing, making available, …. That would be remarkable. It would turn the world around, and make living structure the norm once again, throughout society, and make the world worth living in again. Reflections/Projections 2004 58
Is this Computer Science? public static void stuff(int n){ doit(n, 0, 1, 2); } public static void doit(int n, int f, int t, int a){ if (n == 1) move(n, f, t); else { doit(n-1, f, a, t); move(n, f, t); doit(n-1, a, t, f); } } Reflections/Projections 2004 59
Is this interesting? Reflections/Projections 2004 60
What is random? l What does java. util. Random guarantee? Ø What about next. Int()? Ø What about really, really random? l What is java. security. Secure. Random Ø How can we use this in a program? Ø Why would we want to use it in a program? l What about random. org Ø What is pseudo-random and do we care? Ø What’s the stuff about the European Union? Reflections/Projections 2004 61
Random, Linear, Non-linear l Can we fake the source of data from random. org? Ø How is this source certified? Ø Is this a curiousity or a useful tool? l What about Las Vegas, slot machines, and poker? Ø What about electronic voting? Ø Why is regulation the way it is? Reflections/Projections 2004 62
Beg, Borrow, Steal Reflections/Projections 2004 63
go go gophers Reflections/Projections 2004 64
Derived, but attributed! Reflections/Projections 2004 65
http: //creativecommons. org Reflections/Projections 2004 66
http: //creativecommons. org Reflections/Projections 2004 67
Reflections/Projections 2004 68
Back to the Future � How will we know when we get there? Reflections/Projections 2004 69
A Future for Computer Science? Reflections/Projections 2004 70
What does the Internet look like? Reflections/Projections 2004 71
Reflections/Projections 2004 72
Reflections/Projections 2004 73
Implications of the 80/20 Rule l What is the 80/20 rule? Ø Applications to programming? Ø Pareto’ Law or Principle l What is a power law and what does it model? Ø Distribution of human heights Ø Distribution of city populations Ø Normal v Log-log linear Ø From Zipf to the Web Reflections/Projections 2004 74
What is a scale-free network l From Erdos numbers to random graphs to Internet Ø What happened with Strogatz and Barabasi? Ø Modeling and predicting Ø Computer Science? l Growth and Preferential Attachment Ø Networks grow Ø The rich get richer Ø Science and Politics? Reflections/Projections 2004 75
Network Models (Barabasi) l Differences between Internet, Kazaa, Chord Ø Building, modeling, predicting l Static networks, Dynamic networks Ø Modeling and predicting l Random and Scale-free Ø Implications? l Structure and Evolution Ø Product and process Reflections/Projections 2004 76
Alan Kay: Turing Award 2004 "Simple things should be simple. Complex things should be possible". "The best way to predict the future is to invent it" 77 Reflections/Projections 2004 SCH
- Slides: 77