Minggu, 18 Maret 2012

Ciri-ciri Orang Kena Diabetes

Diabetes adalah penyakit kronis yang bisa memicu berbagai komplikasi jika tidak dikontrol dengan baik. Untuk itu ketahui ciri-ciri yang dimiliki seseorang jika terkena diabetes.

Penyakit diabetes adalah gangguan penggunaan glukosa yang terjadi di dalam tubuh. Diabetes tidak terjadi secara begitu saja. Sebelum didiagnosis menderita diabetes iamengalami fase normal, lalu meningkat menjadi prediabetes dan akhirnya menderita diabetes.

Tanda-tanda seseorang terkena diabetes seperti dilansir dari diabeteslibrary, Kamis, (23/2/2012) adalah:

1. Sering buang air kecil
Buang air kecil akan menjadi sering jika terlalu banyak glukosa dalam darah. Jika insulin tidak ada atau sedikit maka ginjal tidak bisa menyaring glukosa untuk kembali ke darah. Lalu ginjal akan menarik tambahan air dari darah untuk menghancurkan glukosa. Hal ini membuat kandung kemih penuh dan orang jadi sering pipis.

2. Sering merasa haus
Karena sering buang air kecil, Anda akan menjadi lebih sering haus, karena proses penghancuran glukosa yang sulit maka air di dalam darah tersedot untuk menghancurkannya. Sehingga seseorang perlu minum lebih banyak untuk menggantikan air yang hilang.

3. Berat badan turun cepat
Pada penderita diabetes tipe 1 (faktor genetik). Pankreas berhenti membuat insulin akibat serangan virus pada sel-sel pankreas atau respons autoimun. Akibatnya tubuh sulit mencari sumber energi karena sel-sel tidak memperoleh glukosa sehingga memecah jaringan otot dan lemak untuk energi sehingga berat badan terus menyusut.

Pada penderita diabetes tipe 2 (faktor perubahan gaya hidup), penurunan berat badan terjadi secara bertahap dengan peningkatan resistensi insulin sehingga penurunan berat badan tidak begitu terlihat.

4. Merasa lemah dan gampang kelelahan
Karena produksi glukosa terhambat sehingga sel-sel makanan dari glukosa yang harusnya didistribusikan ke semua sel tubuh untuk membuat energi jadi tidak berjalan. Karena sel energi tidak mendapat asupan sehingga orang akan merasa cepat lelah.

5. Sering kesemutan di kaki dan tangan
Gejala ini disebut neuropati. Terjadi secara bertahap karena glukosa dalam darah tinggi dan merusak sistem saraf. Orang-orang sering tidak menyadari bahwa itu salah satu pertanda. Kondisi gula darah tinggi kemungkinan telah terjadi beberapa tahun sebelum diagnosa. Kerusakan saraf dapat menyebar tanpa diketahui.

6. Gejala lain
Selain itu ada pula gejala lain yang bisa muncul seperti penglihatan kabur, kulit kering atau gatal, sering infeksi atau luka dan memar, yang membutuhkan penyembuhan dalam waktu lama merupakan tanda-tanda lain dari diabetes.

Sumber

Jumat, 22 April 2011

Sedikit Cerita Tentang HTML5


HTML5 merupakan salah satu teknologi di bidang web yang lumayan baru. HTML5 mulai booming di tahun 2010 dan pada tahun 2011 ini, menurut ane pengguna HTML5 akan semakin meningkat. Sekitar 1 minggu yang lalu, ane dan beberapa teman ane mengadakan pelatihan HTML5 di kampus ane IT Telkom Bandung. Dan dipostingan kali ini ane akan ceritakan beberapa kelebihan dari HTML5 yang sudah ane coba sendiri.

Beberapa fitur dari HTML5 yang sudah ane coba antara lain :
1. Audio Dan Video
Untuk memutar video maupun audio pada halaman web tanpa plugin video / audio player dari luar
2. Elemen – elemen baru
Pada HTML 5 terdapat beberapa tag form dan tag atribut yang baru seperti email, date, list, url, dsb sehingga akan lebih memudahkan pekerjaan web programmer
3. Canvas
Untuk mengambar objek primitif grafika dan pengolahan citra seperti garis, lingkaran, dsb di halaman web tanpa menggunakan flash ataupun applet java

Pertama ane akan bahas tentang fitur untuk memutar audio dan video dengan HTML5. Fitur audio/video player merupakan salah satu fitur baru yang paling "terasa" di HTML5 ini. Dengan HTML5, om dan tante dapat membuat sebuah audio/video player di halaman web tanpa harus mengimport library player dari luar. Code untuk membuat video/audio player dengan HTML5 sendiri sangat mudah dan cukup pendek. Contohnya adalah sebagai berikut :

Tag video
<video controls="controls" src="Video.mkv" poster="onepiece.jpg" width="300" height="200"></video>

Contoh tampilan video player :


Tag audio
<audio controls="controls" src="Audio.mp3"></audio>

Contoh tampilan audio player :


Sayangnya ekstensi video yang dapat diputar masih sedikit karena HTML5 sendiri masih akan berkembang. Jenis video yang dapat diputar menggunakan video player HTML5 dan sudah ane coba adalah .mkv dan .mp4. Sedangkan untuk audio ane baru mencoba untuk .mp3.. :P

Selain audio/video player, HTML5 menambahkan elemen - elemen baru seperti tipe inputan yang baru untuk form dan beberapa atribut baru. Contoh untuk tipe inputan yang baru adalah email, date, url, range, number, color, dsb. Misal pada inputan dengan tipe email, user harus menginputkan inputan dengan format email. Jika tidak, maka akan secara otomatis muncul peringatan. Untuk contoh atribut baru misalnya required, pattern, autofocus, autocomplete, placeholder, dsb. Misal jika nilai atribut required diset true pada sebuah inputan, maka user tidak boleh mengosongkan inputan tersebut. Jika dikosongkan maka akan muncul peringatan.

Contoh tag untuk inputan dengan tipe date
<input type="date" name="date" />

Contoh tampilan inputan dengan tipe date :


Fitur terakhir dari HTML5 yang sudah ane coba adalah adanya tag canvas. Dengan tag canvas ini, om dan tante dapat menggunakannya untuk menggambar objek – objek 2D. HTML5 hanya menyediakan canvasnya saja sedangkan untuk membuat objek – objek 2D nya harus menggunakan javascript. Bagi om dan tante yang tertarik pada grafika dan pengolahan citra, kalian dapat membuat aplikasi Ms. Paint kalian sendiri pada halaman web dengan menggunakan tag canvas dan javascipt.

Terakhir, berikut ane share sebuah e-book tentang HTML5 buat om dan tante yang ingin belajar HTML5.

Link e-book HTML5 : E-book HTML5

catatan : HTML5 sendiri masih dalam tahap pengembangan sehingga terdapat tag - tag baru yang belum support di web browser tertentu. Berikut tabel kompatibilitas HTML5 dengan beberapa web browser : http://www.findmebyip.com/litmus

Kamis, 21 April 2011

HipHop for PHP, teknologi di belakang Facebook

Berikut ane kutip dari salah satu developer facebook, Haiping Zhao, tentang salah satu teknologi di belakang kecanggihan Facebook. Mangga dibaca.. :)

One of the key values at Facebook is to move fast. For the past six years, we have been able to accomplish a lot thanks to rapid pace of development that PHP offers. As a programming language, PHP is simple. Simple to learn, simple to write, simple to read, and simple to debug. We are able to get new engineers ramped up at Facebook a lot faster with PHP than with other languages, which allows us to innovate faster.

Today I'm excited to share the project a small team of amazing people and I have been working on for the past two years; HipHop for PHP. With HipHop we've reduced the CPU usage on our Web servers on average by about fifty percent, depending on the page. Less CPU means fewer servers, which means less overhead. This project has had a tremendous impact on Facebook. We feel the Web at large can benefit from HipHop, so we are releasing it as open source this evening in hope that it brings a new focus toward scaling large complex websites with PHP. While HipHop has shown us incredible results, it's certainly not complete and you should be comfortable with beta software before trying it out.

HipHop for PHP isn't technically a compiler itself. Rather it is a source code transformer. HipHop programmatically transforms your PHP source code into highly optimized C++ and then uses g++ to compile it. HipHop executes the source code in a semantically equivalent manner and sacrifices some rarely used features — such as eval() — in exchange for improved performance. HipHop includes a code transformer, a reimplementation of PHP's runtime system, and a rewrite of many common PHP Extensions to take advantage of these performance optimizations.

Scaling PHP as a Scripting Language

PHP's roots are those of a scripting language, like Perl, Python, and Ruby, all of which have major benefits in terms of programmer productivity and the ability to iterate quickly on products. This is compared to more traditional compiled languages like C++ and interpreted languages like Java. On the other hand, scripting languages are known to generally be less efficient when it comes to CPU and memory usage. Because of this, it's been challenging to scale Facebook to over 400 billion PHP-based page views every month.

One common way to address these inefficiencies is to rewrite the more complex parts of your PHP application directly in C++ as PHP Extensions. This largely transforms PHP into a glue language between your front end HTML and application logic in C++. From a technical perspective this works well, but drastically reduces the number of engineers who are able to work on your entire application. Learning C++ is only the first step to writing PHP Extensions, the second is understanding the Zend APIs. Given that our engineering team is relatively small — there are over one million users to every engineer — we can't afford to make parts of our codebase less accessible than others.

Scaling Facebook is particularly challenging because almost every page view is a logged-in user with a customized experience. When you view your home page we need to look up all of your friends, query their most relevant updates (from a custom service we've built called Multifeed), filter the results based on your privacy settings, then fill out the stories with comments, photos, likes, and all the rich data that people love about Facebook. All of this in just under a second. HipHop allows us to write the logic that does the final page assembly in PHP and iterate it quickly while relying on custom back-end services in C++, Erlang, Java, or Python to service the News Feed, search, Chat, and other core parts of the site.

Since 2007 we've thought about a few different ways to solve these problems and have even tried implementing a few of them. The common suggestion is to just rewrite Facebook in another language, but given the complexity and speed of development of the site this would take some time to accomplish. We've rewritten aspects of the Zend Engine — PHP's internals — and contributed those patches back into the PHP project, but ultimately haven't seen the sort of performance increases that are needed. HipHop's benefits are nearly transparent to our development speed.

Hacking Up HipHop

One night at a Hackathon a few years ago (see Prime Time Hack), I started my first piece of code transforming PHP into C++. The languages are fairly similar syntactically and C++ drastically outperforms PHP when it comes to both CPU and memory usage. Even PHP itself is written in C. We knew that it was impossible to successfully rewrite an entire codebase of this size by hand, but wondered what would happen if we built a system to do it programmatically.

Finding new ways to improve PHP performance isn't a new concept. At run time the Zend Engine turns your PHP source into opcodes which are then run through the Zend Virtual Machine. Open source projects such as APC and eAccelerator cache this output and are used by the majority of PHP powered websites. There's also Zend Server, a commercial product which makes PHP faster via opcode optimization and caching. Instead, we were thinking about transforming PHP source directly into C++ which can then be turned into native machine code. Even compiling PHP isn't a new idea, open source projects like Roadsend and phc compile PHP to C, Quercus compiles PHP to Java, and Phalanger compiles PHP to .Net.

Needless to say, it took longer than that single Hackathon. Eight months later, I had enough code to demonstrate it is indeed possible to run faster with compiled code. We quickly added Iain Proctor and Minghui Yang to the team to speed up the pace of the project. We spent the next ten months finishing up all the coding and the following six months testing on production servers. We are proud to say that at this point, we are serving over 90% of our Web traffic using HipHop, all only six months after deployment.

How HipHop Works

The main challenge of the project was bridging the gap between PHP and C++. PHP is a scripting language with dynamic, weak typing. C++ is a compiled language with static typing. While PHP allows you to write magical dynamic features, most PHP is relatively straightforward. It's more likely that you see if (...) {...} else {..} than it is to see function foo($x) { include $x; }. This is where we gain in performance. Whenever possible our generated code uses static binding for functions and variables. We also use type inference to pick the most specific type possible for our variables and thus save memory.

The transformation process includes three main steps:

1.Static analysis where we collect information on who declares what and dependencies,
2.Type inference where we choose the most specific type between C++ scalars, String, Array, classes, Object, and Variant, and
3.Code generation which for the most part is a direct correspondence from PHP statements and expressions to C++ statements and expressions.

We have also developed HPHPi, which is an experimental interpreter designed for development. When using HPHPi you don't need to compile your PHP source code before running it. It's helped us catch bugs in HipHop itself and provides engineers a way to use HipHop without changing how they write PHP.

Overall HipHop allows us to keep the best aspects of PHP while taking advantage of the performance benefits of C++. In total, we have written over 300,000 lines of code and more than 5,000 unit tests. All of this will be released this evening on GitHub under the open source PHP license.

Learn More this Evening

This evening we're hosting a small group of developers to dive deeper into HipHop for PHP and will be streaming this tech talk live. Check back here around 7:30pm Pacific time if you'd like to watch.

As I'm sure there will be plenty of questions, starting this evening take a look at the HipHop wiki or join the HipHop developer mailing list. You'll also find us at FOSDEM, SCALE, PHP UK, ConFoo, TEK X, and OSCON over the next few months talking about HipHop for PHP. We're very excited to evolve HipHop into a thriving open source project along with all of you.

sumber : HipHop for PHP

Selasa, 19 April 2011

The Sims 1 Jadul :P



Buat post pertamax ini ane mau cerita tentang 1 game yg udah lama banget keluarnya, tapi buat ane masih asik buat dimainin. Kenapa ane masih main the sims 1 padahal udah ada the sims 3?jawabannya adalah karena kompi ane yang jadul. Jadi ga kuat buat main the sims 3..hehehe. Anyway, game The Sims 1 ini dibuat oleh seorang game designer bernama Will Wright dan pertama kali keluar tahun 2000. Setelah itu, muncul 7 buah expansion pack (the sims living large, the sims house party, the sims hot date, the sims vacation, the sims unleashed, the sims superstar dan the sims makin' magic) untuk the sims 1 ini dengan expansion pack terakhir adalah the sims makin' magic yang keluar tahun 2003 lalu.

Game play dari the sims adalah simulasi kehidupan manusia sehari-hari mulai dari tidur, mandi, nonton tv, berlibur, makan, bekerja, dsb. Seperti game simulasi pada umumnya, pada game the sims ini juga tidak terdapat goal/tujuan yang jelas atau dengan kata lain game seperti ini tidak ada tamatnya (tamat kalo pemainnya bosan.. :D). Pas ane kuliah gamepro dulu :P, game-game seperti ini biasanya dirancang agar si pemain membuat goal sendiri. Nah kalo ane biasanya tujuan dari main the sims ini adalah merancang rumah beserta isinya. Ya itung-itung bikin rencana kalo nantinya punya rumah sendiri..hehehe

Beberapa yang menarik dari game the sims 1 ini adalah barang-barang untuk keperluan rumah yang cukup banyak dengan fungsionalitas yang bermacam-macam. Kalo om dan tante main ga pake cheat, lumayan susah juga membuat rumah yang bagus yang sesuai idaman :D. Selain itu, ada beberapa tempat yang dapat dikunjungi oleh karakter the sims kita, diantaranya tempat kencan (expansion pack the sims hot date), tempat liburan (expansion pack the sims vacation), studio (expansion pack the sims superstar) dan old town(tempat membeli hewan peliharaan, muncul di expansion pack the sims unleashed). FYI, ane sampe sekarang baru main sampe the sims superstar. Lumayanlah buat hiburan di waktu-waktu ngerjain TA gini (ane mahasiswa tingkat akhir) :P. Ayo om dan tante yang masih main the sims 1 sharing-sharing disini berbagi pengalaman..hehehe :P