CS1: Lecture 6 – String
Dear students, We have been looking at the computer’s role as a calculator, but we will deviate from this theme today. Numbers are not the only thing that computers are good at crunching. They are also really good at crunching communication. They can send out our words (and propaganda) as fast as electricity travels. So, […]
CS1: Lecture 4 – Math Methods
Dear students, Today we introduce the Math class. This class has a bunch of pre-written recipes for computing various mathematical operations. We can see what it all provides by looking at its documentation. I usually find the documentation for a class by searching java ClassName in my favorite search engine. The Math class is full […]
CS1: Lecture 3 – More Math
Dear students, Last time we started writing programs that performed little mathematical calculations for us. We used text to talk to the user in a more friendly way than the calculator. We used int for whole number data, and double for numbers with fractions. We used Scanner to get input. Writing programs is a new […]
CS1: Lecture 2 – Computer as Calculator
Dear students, Last time we inspected several programs and formulated these several decrees made by the designers of Java that explain why our programs are what they are: Decree 1: There is data and there are instructions. Decree 2: Code can be ours, or it can be someone else’s. Decree 3: Data can be mailed […]
CS1: Lecture 1 – Hello, CS1
Dear students, Welcome to CS 145: Programming for New Programmers or CS 148: Programming for Experienced Programmers! It’s important to me that we have a comfortable working relationship. We are, after all, on the same team. You wanted to prepare yourself for a bright future, and so you asked me to give you some homework […]
SENG 440: Lecture 24 – Finish
Dear students, Today we wrap up our course. Let’s recount what happened this semester. In week 1 we examined Kotlin, a language that many of us hadn’t used before—myself included. It seemed like the right thing to do, and that decision was recently validated by Android chief advocate Chet Haase at Google I/O: We’re announcing […]
SENG 440: Lecture 23 – CameraX
Dear students, Today we will create an app called Two-Face that allows the user to take a split image on the front-facing camera. The left half and right half are taken at separate times. We will use the new CameraX API that was just announced at Google I/O. Before I forget, here’s your final TODO: […]
SENG 440: Lecture 22 – Speech Recognition
Dear students, Today we will create an app called Recog that presents anagrams for the user to unscramble. But instead of typing, the user will speak the answer. We’ll use Android’s speech recognition facilities to make this happen. Next lecture we will explore the new CameraX API that was just announced at Google I/O 2019. […]
SENG 440: Lecture 21 – Panning and Zooming
Dear students, Today we will examine two common gestures that occur on mobile platforms: pinch-and-zoom and panning. We won’t create a full app, just a custom view that displays an image and supports these two gestures. First we’ll implement it by just adjusting the bounding rectangle containing the image. Once that works, we’ll switch transform […]
SENG 440: Lecture 20 – Multitouch
Dear students, Today we write an app that solves the problem of choosing of which player goes first in a game. All players place a finger on the phone, and the app chooses one of them randomly. The game is inspired by the commercial app Chwazi. Next lecture we will discuss writing an app that […]