Computer Science at MAMS, taught by Mrs. Taricco, aims to turn students into full stack developers, with instruction in languages such as HTML and Java. The year begins with HTML and CSS, acquired through the development of the student’s personal website (which you are currently visiting). Through the completion of programming tasks, students strengthened their skills with fundamental Java concepts, which then translate into projects such as Apps for Good, where students work in small groups to design an app to address a community need. CS encourages students to collaborate in order to develop logical solutions to real-world problems, a skill which is ever-increasingly important in today’s world. Scroll down to see some of programming work!
Stars is a program that randomly generates ten stars of various sizes and colors, and draws them out onto a Java Applet. This is done by using the java.util.Random(); class to randomly generate RGB values for the color of the start, and random (x, y) coordinates for the center of the star, and a value for the distance from a point on the star to the center. Then, by using the Java Math class, 10 points were plotted from the center, and joined together to create the stars. Shown here is the code I wrote for this program, and an example output of what it returns.
Bulgarian Solitaire is a program that generates a random configuration of cards, and then rearranges the decks of cards until the desired configuration of cards is reached (decks of cards with 1, 2, 3, 4, 5 cards, and so on, in no particular order). The cards are rearranged by taking one card from each of the existing pile, and making a new deck of cards with those cards (for example, one shuffle of the deck [20, 4, 9, 16, 6] yields [19, 3, 8, 15, 5, 5]). In order for this to work, the total number of cards in the original configuration must be a triangular number. This is accounted for in my program, which is shown here.
During C and D Term, we worked in groups of 3-4 members to develop an app that would address a community need. I worked with Smita Bhogle and Diksha Sriram to build Personal Record, an app that generates a playlist of songs for a run given data about the user, their music preferences, and the type of run they will be going on.
Many runners prefer running while listening to music. Unfortunately, asynchronous beats to a run interrupt the rhythm of runners, which forces runners to constantly change their music while running. This diverts focus from the exercise itself, reducing the efficacy of the run.
Our app creates playlists for runners to use based on user-inputted information, type of run, preferred genre of music, and duration of run to match the progression of ideal BPM for a run. This encourages runners to optimize progress, without added concern of music regulation. This is done with the assistance of a sorting algorithm, which searches a data set of 40,000 songs to find the most optimal combination of songs to play during a specific run. The heart rate of a runner over an interval of time is projected based on biometric data, as well as the type of exercise chosen, and songs are paired to the run by their tempo.
Currently, our app is capable of generating a list of songs that best fit a workout. In the future, we would like to be able to play the songs directly on the app through the assistance of streaming platforms such as Spotify or YouTube. Additionally, we would like access to more robust libraries of music to generate playlists from.