diff --git a/content/archives/2012/01/_index.id.md b/content/archives/2012/01/_index.id.md new file mode 100644 index 0000000..1d250a6 --- /dev/null +++ b/content/archives/2012/01/_index.id.md @@ -0,0 +1,3 @@ +--- +title: Jan +--- diff --git a/content/archives/2012/01/_index.md b/content/archives/2012/01/_index.md new file mode 100644 index 0000000..1d250a6 --- /dev/null +++ b/content/archives/2012/01/_index.md @@ -0,0 +1,3 @@ +--- +title: Jan +--- diff --git a/content/archives/2012/06/_index.id.md b/content/archives/2012/06/_index.id.md new file mode 100644 index 0000000..4f4f4d8 --- /dev/null +++ b/content/archives/2012/06/_index.id.md @@ -0,0 +1,3 @@ +--- +title: Jun +--- diff --git a/content/archives/2012/06/_index.md b/content/archives/2012/06/_index.md new file mode 100644 index 0000000..aab6602 --- /dev/null +++ b/content/archives/2012/06/_index.md @@ -0,0 +1,3 @@ +--- +title: Jun +--- diff --git a/content/archives/2012/08/_index.id.md b/content/archives/2012/08/_index.id.md new file mode 100644 index 0000000..cf28ed7 --- /dev/null +++ b/content/archives/2012/08/_index.id.md @@ -0,0 +1,3 @@ +--- +title: Aug +--- diff --git a/content/archives/2012/08/_index.md b/content/archives/2012/08/_index.md new file mode 100644 index 0000000..cf28ed7 --- /dev/null +++ b/content/archives/2012/08/_index.md @@ -0,0 +1,3 @@ +--- +title: Aug +--- diff --git a/content/archives/2012/10/_index.id.md b/content/archives/2012/10/_index.id.md new file mode 100644 index 0000000..8422ca4 --- /dev/null +++ b/content/archives/2012/10/_index.id.md @@ -0,0 +1,3 @@ +--- +title: Okt +--- diff --git a/content/archives/2012/10/_index.md b/content/archives/2012/10/_index.md new file mode 100644 index 0000000..c22d921 --- /dev/null +++ b/content/archives/2012/10/_index.md @@ -0,0 +1,3 @@ +--- +title: Oct +--- diff --git a/content/archives/2012/12/_index.id.md b/content/archives/2012/12/_index.id.md new file mode 100644 index 0000000..c00f7ed --- /dev/null +++ b/content/archives/2012/12/_index.id.md @@ -0,0 +1,3 @@ +--- +title: Des +--- diff --git a/content/archives/2012/12/_index.md b/content/archives/2012/12/_index.md new file mode 100644 index 0000000..f92a4e5 --- /dev/null +++ b/content/archives/2012/12/_index.md @@ -0,0 +1,3 @@ +--- +title: Dec +--- diff --git a/content/archives/2012/_index.id.md b/content/archives/2012/_index.id.md new file mode 100644 index 0000000..87cdfa9 --- /dev/null +++ b/content/archives/2012/_index.id.md @@ -0,0 +1,3 @@ +--- +title: 2012 +--- diff --git a/content/archives/2012/_index.md b/content/archives/2012/_index.md new file mode 100644 index 0000000..87cdfa9 --- /dev/null +++ b/content/archives/2012/_index.md @@ -0,0 +1,3 @@ +--- +title: 2012 +--- diff --git a/content/tutorials/membaca-binary-secara-manual/feature-binary.jpg b/content/tutorials/membaca-binary-secara-manual/feature-binary.jpg new file mode 100644 index 0000000..4e6bbb4 Binary files /dev/null and b/content/tutorials/membaca-binary-secara-manual/feature-binary.jpg differ diff --git a/content/tutorials/membaca-binary-secara-manual/index.id.md b/content/tutorials/membaca-binary-secara-manual/index.id.md new file mode 100644 index 0000000..eb29d89 --- /dev/null +++ b/content/tutorials/membaca-binary-secara-manual/index.id.md @@ -0,0 +1,155 @@ +--- +title: "Membaca Binary Secara Manual" +description: "Bagaimana membaca sekumpulan angka 0 dan 1 (Binary) menjadi angka desimal. Kemudian cara mengkonversi desimal ke text (ASCII) menggunakan keyboard & Notepad" +# linkTitle: +date: 2012-01-08T04:29:52+07:00 +lastmod: +draft: false +noindex: false +# comments: false +nav_weight: 1000 +# nav_icon: +# vendor: bootstrap +# name: toggles +# color: '#e24d0e' +series: + - Ilmu Komputer +categories: + - TIL +tags: + - Binary +images: +# menu: +# main: +# weight: 100 +# params: +# icon: +# vendor: bs +# name: book +# color: '#e24d0e' +authors: + - ditatompel +--- + +Sebenarnya artikel ini udah lama. Beberapa saya pungut dari tulisannya om **Capsoel** di **X-Code Magazine edisi 6** dan sisanya *Googling*. Saya coba angkat dan share disini karena teman saya yang tahun lalu melamar kerja di suatu perusahaan ujian pertamanya *covert Binary* ke *Decimal* dengan cara penghitungan manual. Semoga berguna. + + + +``` +01000100011001010111011001101001011011000111101001100011001100000110010001100101 +``` + +Apa itu? kenapa hanya angka `0` dan `1`? Saya yakin tidak semua orang (bahkan yang setiap harinya utak atik komputer) mengerti bagimana membaca **Binary**. + +Sederetan angka 0 dan 1 ini adalah kode **binary**. Pertama, saya akan menunjukan bagaimana membaca sekumpulan angka 0 dan 1 tersebut sebagai angka **desimal**. Kemudian saya baru menunjukan bagaimana cara menggunakan angka tersebut diterjemahkan ke *text* (atau **ASCII**) menggunakan *keyboard* anda dengan *software* bawaan Windows, yaitu `notepad` (Dulu saya coba di notepadnya **Windows XP**). + +Sebagai contoh mudah: + +``` +10101 +``` + +pertama, bayangkan 5 digit di atas adalah sebuah slot kosong: + +``` +_ _ _ _ _ +``` + +Cara membaca **binary** adalah dari kanan ke kiri. +* Slot **pertama** dari kanan mewakili nilai **1**, +* slot **kedua** dari kanan mewakili nilai **2**, +* slot **ketiga** mewakili nilai **4**, +* slot **keempat** mewakili nilai **8**, +* slot **kelima** mewakili **16**, +* dan seterusnya hingga slot ke 8. + +``` +slot 1 = 1 +slot 2 = 2 +slot 3 = 4 +slot 4 = 8 +slot 5 = 16 +slot 6 = 32 +slot 7 = 64 +slot 8 = 128 +``` + +Dengan memberikan angka `1` atau `0` pada slot-slot tersebut, kita menentukan nilai pada slot tersebut. 1 bernilai "`true`", dan 0 bernilai "`false`". Sebagai contoh: +* nilai bilangan **desimal** `1` dalam **binary** adalah `1`, +* nilai bilangan **desimal** `2` dalam **binary** adalah `10`, +* nilai bilangan **desimal** `4` dalam **binary** adalah `100`. + +Kenapa bisa begitu? Kembali lagi ke slot-slot di atas. + +Slot pertama dari kanan bernilai `1`, jadi jika slot pertama adalah angka `1` maka nilainya juga `1` dan bilangan binernya adalah `1`. + +``` +_ _ _ _ 1 +``` + +Untuk **desimal** `2`, bilangan **biner** = `10` + +karena slot pertama bernilai 1 diberi angka 0 (*false*) dan slot ke 2 diberi angka 1 (*true*) + +``` +_ _ _ 1 0 +``` + +Untuk **desimal** `4`, bilangan **biner** = `100` + +karena slot pertama bernilai 1 diberi angka 0 (*false*) dan slot ke 2 diberi angka 0 (*false*) dan baru slot ketiga yg bernilai 4 diberi angka 1 (*true*) + +``` +_ _ 1 0 0 +``` + +Lalu gimana klo **desimal** `3`? Kan ga ada nilainya pada slot? `1 + 2 = 3`. Jadi, nilai **desimal** `3` pada **binary** adalah `11` +``` +_ _ _ 1 1 +``` + +klo desimal `5`? `1 + 4 = 5` berarti bilangan *binernya* `101`. + +``` +_ _ 1 0 1 +``` + +Lalu jika kode binernya panjang banget seperti ini? Gimana bacanya ke **ASCII** / *text*? + +``` +01000100011001010111011001101001011011000111101001100011001100000110010001100101 +``` + +Pisahkan dulu menjadi 8 digit: +``` +01000100 01100101 01110110 01101001 01101100 01111010 01100011 00110000 01100100 01100101 +``` + +Lalu convert ke bilangan **decimal** + +``` +01000100 = 68 +01100101 = 101 +01110110 = 118 +01101001 = 105 +01101100 = 108 +01111010 = 122 +01100011 = 99 +00110000 = 48 +01100100 = 100 +01100101 = 101 +``` + +Lalu ASCIInya mana? + +Hehehe.. Sekarang giliran notepad menerjemahkannya.. (dulu ane coba ni teknik pake Notepad di **Windows XP**, kaga tau sekarang jalan di **Windows 7** atau tidak). + +Caranya tahan ALT + Angka desimal yang sudah ditranslate. + +ALT + 68 = `D` +ALT + 101 = `e` + +dan seterusnya, silahkan dicoba dan dibuktikan.. + +Atau kalau mau mudah bisa menggunakan translator binary yang banyak beredar di internet.. Misalnya saja `http://home.paulschou.net/tools/xlate/`. + diff --git a/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x360_resize_q75_box.jpg b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x360_resize_q75_box.jpg new file mode 100644 index 0000000..71f705a Binary files /dev/null and b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x360_resize_q75_box.jpg differ diff --git a/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x640_resize_q75_box.jpg b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x640_resize_q75_box.jpg new file mode 100644 index 0000000..d1f9eab Binary files /dev/null and b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_0x640_resize_q75_box.jpg differ diff --git a/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_5e08e86507bfd7c1974366cecada629b.webp b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_5e08e86507bfd7c1974366cecada629b.webp new file mode 100644 index 0000000..09ca3e6 Binary files /dev/null and b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_5e08e86507bfd7c1974366cecada629b.webp differ diff --git a/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_af51eb571bef11e4d20546de28943796.webp b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_af51eb571bef11e4d20546de28943796.webp new file mode 100644 index 0000000..7379cbf Binary files /dev/null and b/resources/_gen/images/tutorials/membaca-binary-secara-manual/feature-binary_hu525e3518216da19dbe158344c0acfded_720531_af51eb571bef11e4d20546de28943796.webp differ