diff --git a/Documentation1.md b/Documentation1.md deleted file mode 100644 index 28f94fa..0000000 --- a/Documentation1.md +++ /dev/null @@ -1,19 +0,0 @@ -# Name: - -## Examples: -Insert examples here. - -## Description: -Insert description here - -## Syntax: -Demonstrate syntax here - -##Parameters: -Name and describe parameters here - -##Returns: -What type of data does it return? - -##Other notes: -Anything else? diff --git a/Documentation2.md b/Documentation2.md deleted file mode 100644 index 28f94fa..0000000 --- a/Documentation2.md +++ /dev/null @@ -1,19 +0,0 @@ -# Name: - -## Examples: -Insert examples here. - -## Description: -Insert description here - -## Syntax: -Demonstrate syntax here - -##Parameters: -Name and describe parameters here - -##Returns: -What type of data does it return? - -##Other notes: -Anything else? diff --git a/Documentation3.md b/Documentation3.md deleted file mode 100644 index 28f94fa..0000000 --- a/Documentation3.md +++ /dev/null @@ -1,19 +0,0 @@ -# Name: - -## Examples: -Insert examples here. - -## Description: -Insert description here - -## Syntax: -Demonstrate syntax here - -##Parameters: -Name and describe parameters here - -##Returns: -What type of data does it return? - -##Other notes: -Anything else? diff --git a/FunctionsChallenge/FunctionsChallenge.pde b/FunctionsChallenge/FunctionsChallenge.pde new file mode 100644 index 0000000..8de209f --- /dev/null +++ b/FunctionsChallenge/FunctionsChallenge.pde @@ -0,0 +1,40 @@ +//make a quadratic formula +float[] quadraticForm(float numberA, float numberB, float numberC) { + float answers[]= new float[2]; + answers[0] = ((-numberB) + (sqrt((numberB*numberB) - (4* numberA* numberC))))/(2*numberA); + answers[1] = ((-numberB) - (sqrt((numberB*numberB) - (4* numberA* numberC))))/(2*numberA); + return answers; +} +//find the initial velocity +float initialVelocity(float vF, float a, float x) { + float answer; + answer = sqrt(sq(vF) + (2*a*x)); + return answer; +} +//spam the picture Kappa on the screen +void spamKappaInTheChat() { + PImage KAPPA; + PImage KAPPAKID; + KAPPA = loadImage("KAPPA.png"); + KAPPAKID = loadImage("KAPPAKID2.jpg"); + if (mousePressed) { + fill(255); + textSize(40); + String Kappa = "EVERYBODY SPAM KAPPA IN THE CHAT"; + text(Kappa, 25, 50); + image(KAPPA, random(800), random(600)); + image(KAPPAKID, 0,100); + } +} + +//size +void setup() { + size(800, 600); +} +//print the answers for the 2 equations and the command. +void draw() { + background(0); + println(quadraticForm(1,2,1)); + println(initialVelocity(1, 0, 0)); + spamKappaInTheChat(); +} \ No newline at end of file diff --git a/FunctionsChallenge/data/KAPPA.png b/FunctionsChallenge/data/KAPPA.png new file mode 100644 index 0000000..1896c49 Binary files /dev/null and b/FunctionsChallenge/data/KAPPA.png differ diff --git a/FunctionsChallenge/data/KAPPAKID.jpg b/FunctionsChallenge/data/KAPPAKID.jpg new file mode 100644 index 0000000..4f72b1f Binary files /dev/null and b/FunctionsChallenge/data/KAPPAKID.jpg differ diff --git a/FunctionsChallenge/data/KAPPAKID2.jpg b/FunctionsChallenge/data/KAPPAKID2.jpg new file mode 100644 index 0000000..381640b Binary files /dev/null and b/FunctionsChallenge/data/KAPPAKID2.jpg differ diff --git a/initialVelocity() b/initialVelocity() new file mode 100644 index 0000000..ab1b6a9 --- /dev/null +++ b/initialVelocity() @@ -0,0 +1,21 @@ +# Name: +intialVelocity() + +## Examples: +println(initialVelocty(1,0,0)); + +rect(initialVelocity(1,0,0), 100,50,50); + +## Description: +Finds the inital velocity by using a simple physics equation, with the knowlege of the final velocity, acceleration and displacement + +## Syntax: +initialVelocity(vF,a,x) + +##Parameters: +vF float: Final Velocity +a float: Acceleration +x float: Displacement + +##Returns: +float diff --git a/quadraticForm() b/quadraticForm() new file mode 100644 index 0000000..2b42b67 --- /dev/null +++ b/quadraticForm() @@ -0,0 +1,24 @@ +# Name: +quadraticForm() + +## Examples: +println(quadraticForm(5,6,7)); + +rect (quadraticForm(1,3,2),50,50,50) + +## Description: + Finds the quadratic formula for any three numbers you imput. Will produce both answers. + +## Syntax: +quadratricForm(a,b,c) + +##Parameters: +a float: the coefficient of the x squared value +b float: the coefficient of the x value +c float: the constant + +##Returns: +float + +##Other notes: + diff --git a/spamKappaInTheChat() b/spamKappaInTheChat() new file mode 100644 index 0000000..facca47 --- /dev/null +++ b/spamKappaInTheChat() @@ -0,0 +1,16 @@ +# Name: +spamKappaInTheChat() + +## Examples: +spamKappaInTheChat(); + +## Description: +When the mouse is pressed, text will appear on screen along with the appearance of Kappa on the screen at random locations. +There is no parameters, so '()' will be the only thing after this function + +## Syntax: +spamKappaInTheChat(); + +#Returns: +void +