Skip to content

new file in 2 and 3 #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions AverageCalc.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import java.util.*;

class AverageCalc {
public void average () {
Scanner sc = new Scanner(System.in);

System.out.println("enter some numbers with a space inbetween (eg. 5.1 343 340.12 99)");
String numbers = sc.nextLine();

String[] n = numbers.split(" ");
double[] numberSplit = new double[n.length];

for (int i=0;i<n.length;i++) {
numberSplit[i] = Integer.parseInt(n[i]);
}

double tot = 0;
for (int i=0;i<numberSplit.length;i++) {
tot += numberSplit[i];
}

double average = (tot)/(n.length);

System.out.println(average);
}
}
9 changes: 9 additions & 0 deletions branch2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
branch2 new file
random stuff

eheheheh more stuff

dudududuud
baby snark dduudududududu

:)
7 changes: 7 additions & 0 deletions branch3.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
branch3 new file

more stufffff yayyyyy
dududduduudd
momy shak duduuddd

:|
1 change: 1 addition & 0 deletions randomStuff.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
random stuff just for another commit....
1 change: 1 addition & 0 deletions rickroll.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
https://www.youtube.com/watch?v=dQw4w9WgXcQ rickroll do not go to link