Created
October 7, 2024 14:36
-
-
Save wanantope/0eefc565c070698af480abd3591bc309 to your computer and use it in GitHub Desktop.
11_21_homework
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//11.21 | |
public class Main { | |
public static void main(String[] args) { | |
int[] yanvar = new int[31]; | |
int sum = 0; | |
for (int x = 0; x < yanvar.length; x++) { | |
yanvar[x] = (int) (Math.random() * 100); | |
sum = sum+x; | |
} | |
System.out.println(sum); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment