Skip to content

Instantly share code, notes, and snippets.

View abdallahmalima's full-sized avatar

Abdallah Antony abdallahmalima

View GitHub Profile
@abdallahmalima
abdallahmalima / AdbCommands
Created April 13, 2024 04:25 — forked from Pulimet/AdbCommands
Adb useful commands list
adb help // List all comands
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
@abdallahmalima
abdallahmalima / dry.css
Created November 12, 2022 02:20
Check DRY principle
.greetings {
font-family: Arial, sans-serif;
font-size: 1.5rem;
}
.greetings.english {
background-color: #000;
color: #FFF;
}
.greetings.spanish {
@abdallahmalima
abdallahmalima / sample.js
Created November 12, 2022 02:17
check DRY principle
const greet = (message, name) => {
console.log(`${message}, ${name}!`)
}
greet('Hello', 'John');
greet('Hola', 'Antonio');
greet('Ciao', 'Luigi')
@abdallahmalima
abdallahmalima / sample.css
Last active November 12, 2022 02:09
Check DRY principle
/*=======================================*\
this code does Not follow DRY principle
\*=======================================*/
.cat {
font-family: "Times New Roman", Times, serif;
font-size: 1rem;
color: #FFF;
}
@abdallahmalima
abdallahmalima / dry.js
Last active November 12, 2022 02:13
Test if code is DRY
/*=======================================*\
this code does Not follow DRY principle
\*=======================================*/
const pets = ['Cat', 'Dog', 'Bird', 'Fish', 'Frog', 'Hamster', 'Pig', 'Horse', 'Lion', 'Dragon'];
// Print all pets
console.log(pets[0]);
console.log(pets[1]);
console.log(pets[2]);
console.log(pets[3]);