top of page

THANKSGIVING!

Writer: Amulya Malapaka
Amulya Malapaka
Nov 17, 2018
1 min read

IT'S THANKSGIVING!!! Want to know what I'm thankful for? I'm thankful for the beautiful weather we've been having.(Yes that was sarcastic.) I'm actually really excited for the nice five day weekend we're about to have! So to express that excitement, let's write a fun Thanksgiving themed program, because we can use programs to express ourselves :)


Write a program that takes names to create random phrases. You can create an array of names and an array of Thanksgiving themed phrases, and use a random function to put a random name and phrase together.


//create a name array(var names = ["x", "y", "z"];)

//create an array of phrases(var phrases = ["Happy thanksgiving, ", "Have a great break, "];)


// make a random function


// output phrases[randNum] + names[randNum]


To go with it, here is some pumpkin pie chai tea!

https://www.geniuskitchen.com/recipe/pumpkin-pie-chai-tea-382378


Have a great break,


Amulya <3

 
 
 

Recent Posts

See All
Well it's been a while, huh.

Welcome back girls and boys, we're in for a fun ride :) As the end of the school year approaches us I'm sure we're excited for a summer...

 
 
 

1 Comment


lubeck1089
lubeck1089
Dec 03, 2018

String[] names = new String[3];

names[0] = "Bob";

names[1] = "Joe";

names[2] = "Billy";

String[] phases = new String[2];

phrases[0] = ", eat lots of turkey!";

phrases[1] = ", spend time with your family!";

System.out.print(names[(int) (Math.random() * 2)] + phrases[(int) Math.random()]);

Like
bottom of page