Category: Programming

Type casting in PHP

PHP does not support explicit type definition in variable declaration. For example, you CANNOT declare a variable as follows: In PHP, a variable’s type is determined by the context in…

Java and Memory

From a programming point of view, there are essentially six different places to store data on your computer. The fastest storage is the registers since this memory resides inside the…

Java JAR, WAR, and EAR files

.ear, .war, and .jar files are simply files zipped using Java jar tool. Each file is created for a different purpose: .jar files Jar (Java Archive) files contain libraries, resources…

jQuery Quick Start

Before learning jQuery, you should learn HTML, CSS, JavaScript, and learn how to debug JavaScript. You should also be familiar with JSON. Knowing XML will also be helpful. jQuery is…

Jupyter Cheat Sheet

Jupyter is an online notebook. You can run python, markup, bash commands, generate visualizations, and much more in the notebook and display the output as well within the same page.…

Java Linked List

The Internet is full of code examples on how you can create your own LinkedList class. Java provides and very easy to use class LinkedList. Following is an example on…

How to encrypt a string in PHP

The following code encrypts a string. crypt() function encrypts the string. The last line prints the encrypted string. There is no such function called decrypt(). This is because crypt uses…

PHP Unit Testing with SimpleTest

What is Unit Testing Most developers agree that testing is important but few test their code. Even fever do it methodically. Many developers do not realize that there is a…