# Computer Science

At Mass Academy, Computer Science is taught by Mrs. Taricco. In Computer Science, we start by learning HTML and CSS in order to get familiar with the process of coding, and then we move into Java. Mrs. Taricco teaches us the basics, and then it is up to us to figure out how to tell the code to accomplish the intended tasks. This course follows the AP Computer Science A curriculum so in the spring you can take the AP test. In C and D Term Mrs. Taricco introduces the Apps For Good project to allow us to go through the process of designing, implementing, an testing an app.

#### Manipulating An Image

This assignment was designed for us to become familiar with iterations. This specific method takes an image and converts the color of every single one of its pixels to its negative. In order to make sure the image is completely converted, the code has to reach every single pixel. This was a really fun method because after you selected an image, you could watch the image convert to negative colors.

#### Throwing a Dart to Calculate Pi

This code asks for a number of throws –an input– and throws it onto a board –randomly choose coordinates for a point in the area contained by a unit circle. Based on the (x,y) coordinates, the code will then calculate the value of pi. Even with a low number of throws an accurate value can be returned. I enjoyed this project because it combined a lot of different classes like the Math, Random, and Scanner classes, alongside the for loop (fun fact, I initialize all of my scanners as floof). At the bottom of the PDF, you can see the outputs the method calculated for various inputs.

#### Apps For Good

Apps for Good is a project introduced to us by Mrs. Taricco. We were placed into groups and designed, implemented, and tested an app. I was grouped with Venkat and McKenna and we chose to create an app that would be able to recommend a new food for the users to try. We wanted to create this app because we felt as if there was a gap in the market that could be filled. Our MVP, or minimum valuable product, would be an app that can take in the user’s likes and dislikes of various foods; then the app would be able to recommend a new food for the user to try based upon the input. Our algorithm used SVD or singular value decomposition to create matrices with the user input and then manipulate the matrices to return an ingredient to try. In addition, our app made use of Shared Preferences to store the user’s likes and dislikes and be able to refer to them each time the app is opened. This project allowed us to use the programming language through the year–Java–and learn how to use Android Studio to create an app.