This file contains 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
//initializing parent class | |
class A{ | |
int x;//variable as example | |
A(int _x){//constructor | |
x = _x;//init | |
} | |
} | |
//extending class | |
class Derived extends A{ | |
int y;//variable as example |
This file contains 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
snowflake[] snowflakes; | |
snowflake snowflake; | |
float wind = 4.0; | |
int snowAmount; | |
void setup(){ | |
size(600,400); | |
background(0); | |
snowAmount = 400; | |
snowflakes = new snowflake[snowAmount]; | |
for(int i = 0; i < snowflakes.length; i++){ |