Showing posts with label math. Show all posts
Showing posts with label math. Show all posts

Wednesday 22 October 2014

Not dari suatu pernyataan

1. A = Budi anak yang baik
Not dari statement A = Budi bukan anak yang baik

2. B = Budi bukan anak yang baik
Not dari statement B = Budi anak yang baik

Petunjuk: kata tidak dihilangkan, tidak ada kata tidak tambahkan kata tidak.

Sunday 23 February 2014

Harga 1 bungkus rokok = 13000. Berapa harga per batang? Jika jumlah batang per bungkus = 12

Sunday 16 February 2014

Manakah yang lebih besar?

a, b, c
a + b = c
manakah yang lebih besar a atau c?

a - b = c
manakah yang lebih besar a atau c?

a * b = c
manakah yang lebih besar a atau c?

a / b = c
manakah yang lebih besar a atau c?


Thursday 13 February 2014

Rumus sisa bagi

1. Rumus sisa bagi
Contoh: 5 / 3 = .....1 sisa 2

Langkah 1. Pertama kita harus tahu hasil/jawaban yang bener itu bagaimana, dari situ kita bisa main tebak-tebakan sedikit.

Langkah 2. Masukkan angka-angkanya kedalam gelas eh.. variabel
Soal diatas: 5 / 3 = 1 sisa 2
A = 5
B = 3
C = 1
D = 2
Jadi, yang mau kita cari diatas 5 / 3 = 1 sisa 2 itu berubah menjadi:
A / B = C sisa D

Langkah 3.Kreatifitas
angka 1 (C) bisa didapat dari apa saja?
1. 3-2 atau B-D

2 . Angka 2 (D) bisa didapat dari?
5- 3 atau A - B

Test:
C = B-D
= B-(A-B)
= B-A+B

Monday 27 January 2014

1. Jumlah gaji = 4 juta 500 perbulan, berapa jumlah gaji perhari kerja perbulan seorang karyawan?
Solusi:
Satuan jawaban = Rupiah / hari
Cara 1 (gampang)
1 bulan = 4 minggu
kerja dari senin - jumat
45 juta /

2. Jika jam kerja Dodi dimulai dari jam 7, jam berapa Dodi pulang, jika dia kerja selama 8 jam?

Monday 22 April 2013

Wisdom of an access-list

We will observe that access-list 1 permit 192.168.1.1 0.0.0.255 is same meaning as access-list 1 permit 192.168.1.253 0.0.0.255. You see that both of these access-list permitting any traffic that are generated by 192.168.1.1 - 192.168.1.255 hosts but why we just don't write it as access-list 1 permit 192.168.1.0 0.0.0.255?

or 

maybe those 3 access-list are all same meaning?

The answer is yes, they are all same meaning.
access-list 1 permit 192.168.1.1 0.0.0.255, and
access-list 1 permit 192.168.1.253 0.0.0.255, and
access-list 1 permit 192.168.1.0 0.0.0.255
are all same meaning.

Later, I will show that is not only 3 access-list variation that we can build to block these address (192.168.1.1 - 192.168.1.255) but many.

How can it be? Well access-list is just an OR operation between IP part, the wildcard mask, and the address of an IP packet.

Any IP packet that have layer 3 address (source) that OR-ed with (IP part OR the wildcard mask) is have same result with result of IP part OR the wildcard mask they will be assumed match.


Well, First, we need a brief wisdom of binary OR operation. You can read it in here:
Second, we will learn bitwise operation behind the access-list. In this steps I will say that an access-list is just an OR operation between A, B and C. Follow me.
Third, we will answer the question.

(1) Please read the blog
(2) Recall one of our access-list: access-list 1 permit 192.168.1.1 0.0.0.255
we can re-say it correctly with: access-list 1 permit A B, where A = 192.168.1.1 and B = 0.0.0.255
We will need another variable C. So now we have A, B, and C variable.
So we re-gather them again:
A = 192.1681.1 = An IP address of an access-list
B = 0.0.0.255 = the wildcard mask of an access-list
and, C = any IP address

(3)Your friend give a hosts-list 192.168.1.3 and 192.168.1.4 to you. They want you to block these host's internet connection. Tell me your A and B on your access-list that you want to built to block the host internet conn.?
Since C = 192.168.1.3 OR 192.168.1.4 = 192.168.1.7
A = 192.168.1.3
B = 0.0.0.4
access-list 1 permit 192.168.1.3 0.0.0.4

A = 192.168.1.3
B = 0.0.0.7
access-list 1 permit 192.168.1.3 0.0.0.7

A = 192.168.1.4
B = 0.0.0.3
access-list 1 permit 192.168.1.4 0.0.0.3

A = 192.168.1.4
B = 0.0.0.7
access-list 1 permit 192.168.1.4 0.0.0.7

A = 192.168.1.7
B = 0.0.0.4
access-list 1 permit 192.168.1.7 0.0.0.4

A = 192.168.1.7
B = 0.0.0.3
access-list 1 permit 192.168.1.7 0.0.0.3

Have you count how many access-list variation that we have in this question? Yes it is 6! Where 6 came from?

2. How much host that will be block accidentally using your access-list?
Answer: If you using 1 one of question number 1 access-list you will