Getting started:
Related tutorials:
import time | |
import random | |
print("Snake and ladder w/o Board - v1.0") | |
class Player: | |
def __init__(self, player_id): | |
self.score = 0 | |
self.player_id = player_id |
// Sum of Digits / Digital Root | |
// In this kata, you must create a digital root function. A digital root is the recursive sum of all the digits in a number. Given n, take the sum of the digits of n. If that value has more than one digit, continue reducing in this way until a single-digit number is produced. This is only applicable to the natural numbers. | |
function digital_root(n) { | |
//return (n - 1) % 9 + 1; | |
var data = `${n}`.split(""); | |
var total = 0; | |
do{ | |
total = 0 | |
if(data.length!=1){ | |
for(var i=0;data.length>i;i++){ |
GREEN='\033[0;32m' | |
NC='\033[0m' # No Color | |
RED='\033[0;31m' | |
clear | |
printf "${GREEN}" | |
printf "===========================================\n" | |
printf "========== JavaScript Versioning ==========\n" | |
printf "========== Author: Jona ==========\n" |
#!/bin/bash | |
# THIS IS FOR JAVASCRIPT VERSIONING | |
GREEN='\033[0;32m' | |
NC='\033[0m' # No Color | |
RED='\033[0;31m' | |
clear | |
printf "${GREEN}" | |
printf "===========================================\n" |
<table class='mbm mhc' border='0' cellpadding='0' cellspacing='0'><tr><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0'></td><td height='4' width='4' bgcolor='##0#0#0' |
var animals = [ | |
{ name: 'Fluffykins', species: 'rabbit' }, | |
{ name: 'Caro', species: 'dog' }, | |
{ name: 'Hamilton', species: 'dog' }, | |
{ name: 'Harold', species: 'fish' }, | |
{ name: 'Ursula', species: 'cat' }, | |
{ name: 'Jimmy', species: 'fish' } | |
] |
// https://jsfiddle.net/mattiasjle/w789neex/ | |
var orders = [ | |
{ amount: 250 }, | |
{ amount: 400 }, | |
{ amount: 100 }, | |
{ amount: 325 } | |
] | |
var totalAmount = orders.reduce(function(sum, order) { | |
return sum + order.amount |
Getting started:
Related tutorials:
#!/bin/bash | |
#DO AFTER CREATE FILE : chmod +x remote.sh && sudo mv remote.sh /usr/bin/remote | |
PS3='Please select remote site ' | |
options=("TEST SERVER" "Quit") | |
select opt in "${options[@]}" | |
do | |
case $opt in | |
"TEST SERVER") | |
ssh [email protected] |