The best semi-conductor??
Silicon is the basis of modern computing in chips but it has some major flaws. Scientists at MIT, UHouston have conducted experiments to show Cubic Boron Arsenide overcomes both these issues.
The Beauty and Joy of Computing��Lecture #5�Algorithms�
https://www.sciencedaily.com/releases/2022/07/220721141459.htm
Put your notes here
UC Berkeley�Teaching Professor �Dan Garcia
CS10 NEWS
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (1)
Garcia
Algorithms: Definitions
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (2)
Garcia
Algorithm: Definition
en.wikipedia.org/wiki/Algorithm
Euclid’s GCD Algorithm�(Wikipedia, Somepics)
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (3)
Garcia
Early Algorithms
Woman Basket Weaving�(Wikipedia, Public Domain)
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (4)
Garcia
Algorithms You've Seen in BJC so far
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (5)
Garcia
Algorithms You May Already Know
Luhn algorithm Credit card number validation | Deflate�Lossless data compression |
PageRank Google’s way to measure web page “reputation” | EdgeRank Facebook’s way to determine news feed sort |
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (6)
Garcia
Building Blocks of Algorithms
Sequencing Application of each step of an algorithm in order given | Selection�Use of Boolean condition to select which of two parts to do |
Iteration Repetition algorithm part # times or until condition met | Recursion The overall algorithm calls itself to help solve the problem on smaller parts,combine result. (we’ll see later) |
🗹
Every algorithm can be constructed using only�Sequencing, Selection, & Iteration!
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (7)
Garcia
Which of the following is false?
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (8)
Garcia
Algorithms: Properties, Expressing
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (9)
Garcia
Properties of Algorithms
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (10)
Garcia
How to Express Algorithms…
A programmer’s spouse says: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.” The programmer comes home with 12 loaves of bread.
Algorithms need to be expressed in a context-free, unambiguous way for all participants!
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (11)
Garcia
Languages for Algorithms
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (12)
Garcia
Algorithms vs. Functions & Procedures
Garcia
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (13)
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (13)
Garcia
Which Language to Choose?
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (14)
Garcia
Programming Languages
C/C++ Good for programming that is close to hardware | Java/C#�Portable code |
Python/Perl/TclTK Fast to write and portable | Scratch/Snap! Good for teaching programming concepts |
Nearly all programming languages are equivalent in terms of being able to express any algorithm!
🗹
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (15)
Garcia
Of 4 languages, what’s the most powerful?
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (16)
Garcia
Different Algorithms demo time!
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (17)
Garcia
Summary
Garcia
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (18)
UC Berkeley “The Beauty and Joy of Computing” : Algorithms (18)
Garcia