Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int led_red_pin = 13;
- int led_orange_pin = 12;
- int led_green_pin = 11;
- void setup()
- {
- pinMode(led_red_pin, OUTPUT);
- pinMode(led_orange_pin, OUTPUT);
- pinMode(led_green_pin, OUTPUT);
- Serial.begin(9600);
- for(int k=1;k<17;k++)
- {
- Serial.print(" Multiply table for ");
- Serial.println(k);
- Serial.println("========================");
- for(int i = 1;i<13;i++)
- {
- Serial.print(k);
- Serial.print(" * ");
- Serial.print(i);
- Serial.print(" = ");
- Serial.println(funMultiply(k,i));
- }
- Serial.println();
- }
- }
- void loop()
- {
- //function call, invoke
- }
- void funLedBlink(int led_pin,int time)
- {
- digitalWrite(led_pin, HIGH);
- delay(time);
- digitalWrite(led_pin, LOW);
- delay(time);
- }
- int funMultiply(int a, int b)
- {
- int m = a * b;
- return m;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement