#include <LiquidCrystal.h>
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
void animasi(String teks, int baris) {
for (int i = 0; i < teks.length(); i++) {
for (int j = 0; j < 10; j++) {
lcd.setCursor(i, baris);
lcd.print((char)random(33, 126));
delay(30);
}
lcd.setCursor(i, baris);
lcd.print(teks[i]);
}
}
void setup() {
lcd.begin(16, 2);
randomSeed(analogRead(0));
animasi("Kelas 4B", 0);
animasi("Kelompok 4", 1);
}
void loop() {
delay(1000);
lcd.clear();
delay(200);
setup();
}