Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void Start()
- {
- int max = 0;
- for (int i = 0; i < 20; i++)
- {
- int a = Random.Range(0, 200);
- tab[i] = a;
- tab2[i] = a * a;
- if (tab2[i] > max)
- {
- max = tab2[i];
- }
- if (tab2[i] % 2 == 0)
- Debug.Log("kwadrat " + a + " jest parzysty i wynosi " + tab2[i]);
- else
- {
- Debug.Log("kwadrat " + a + " jest nieparzysty i wynosi " + tab2[i]);
- }
- }
- Debug.Log("największy kwadrat to" + max);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement