Skip to content

Instantly share code, notes, and snippets.

View 3Shoka's full-sized avatar
🤫
hmm....

Ashokani 3Shoka

🤫
hmm....
View GitHub Profile
@3Shoka
3Shoka / wezterm.lua
Created September 25, 2024 23:06
wezterm configuration file on windows with wsl ubuntu
-- Pull in the wezterm API
local wezterm = require("wezterm")
-- This table will hold the configuration.
local config = {}
-- In newer versions of wezterm, use the config_builder which will
-- help provide clearer error messages
if wezterm.config_builder then
config = wezterm.config_builder()
@3Shoka
3Shoka / spotihosts
Created September 19, 2016 07:01
The hosts file entries to block Spotify audio ad servers.
127.0.0.1 media-match.com
127.0.0.1 adclick.g.doublecklick.net
127.0.0.1 www.googleadservices.com
127.0.0.1 open.spotify.com
127.0.0.1 pagead2.googlesyndication.com
127.0.0.1 desktop.spotify.com
127.0.0.1 googleads.g.doubleclick.net
127.0.0.1 pubads.g.doubleclick.net
127.0.0.1 audio2.spotify.com
127.0.0.1 www.omaze.com
<?php
$a =".";
$spc = " ";
$ulang = 20;
for ($i=0; $i < $ulang; $i++) {
// bikin kondisi angka ganjil
if ($i%2==1) {
// cetak spasi setengah dari total $ulang
<?php
$data = '[{"tanggal":"2016-05-23","nama":"Kotak Amal FO ","cabang":"RY Building","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"Catur Ronis Sainuddin","cabang":"Surabaya","kota":"Surabaya"},{"tanggal":"2016-05-23","nama":"Nono Rosmana","cabang":"Arcamanik","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"Bpk. Hartono","cabang":"Cemara","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"Kotak Amal Cemara","cabang":"Cemara","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"Novi Istiawan H.\/ Ninik Roeslan","cabang":"Monjali","kota":"Yogyakarta"},{"tanggal":"2016-05-23","nama":"Zakky Hazami","cabang":"Terogong","kota":"Jakarta"},{"tanggal":"2016-05-23","nama":"H Yasni Yunus","cabang":"Kiaracondong","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"Kotak Amal Fo Bekasi","cabang":"Bekasi","kota":"Jakarta"},{"tanggal":"2016-05-23","nama":"Kotak Amal Margahayu","cabang":"Margahayu","kota":"Bandung"},{"tanggal":"2016-05-23","nama":"PT. Suzuki Dealer Mobil","cabang":"Cemara","kota":"Bandung"},{"tanggal":"20
@3Shoka
3Shoka / DeretBilangan.php
Created April 26, 2016 09:24 — forked from ad3n/DeretBilangan.php
[PHPID QUIZ] Deret Bilangan
<?php
class DeretBilangan
{
private function isPrima($number)
{
$flag = 0;
for ($i = 1; $i <= $number; $i++) {
if (0 === $number % $i) {
$flag++;
<?php
# n = (n+1)*(n-1)
# dapatkan nilai ganjil genap dan prima
# jumlah masing masing jika deretnya 100
# ganjil (23): x, y, z
# genap (77): a, b, c
# prima ((7)): g, h, i
for($i=1;$i<=100;$i++){
$angka = ($i+1)*($i-1);
@3Shoka
3Shoka / tmux-cheatsheet.markdown
Created April 12, 2016 10:12 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
<?php
class BujurSangkar
{
private $sisi = 7;
private $reserved = array();
public function __construct()
{
for ($i = 1; $i <= $this->sisi * $this->sisi; $i++) {
<?php
class JajarGenjang
{
private $panjang = 18;
private $increment = 1;
private function createLine()
{