package ds; public class BasicBinaryTree<X extends Comparable<X>> { private Node root; private int size; public BasicBinaryTree(){ this.root = null; } public int size(){ return size; } public void add(X item){ … Continued
Author Archives: Mashruf
Datastructures revisited : Implementing Basic Linked List in Java
public class BasicLinkedList<X> { private Node first; private Node last; private int nodeCount ; public BasicLinkedList(){ first = null; last = null; nodeCount = 0; } public void add(X item){ … Continued
Datastructures Revisited: Implementing Stack in JAVA
This is the stack implementation in JAVA package ds; public class BasicStack<X> { private X[] data; private int stackPointer; public BasicStack(){ data = (X[]) new Object[1000]; stackPointer = 0; } public void push(X item){ … Continued
Learning Kotlin : Basics & Functional Programming
Here are some Kotlin basics that I have tried. It might be useful as a quick reference:
Creating a tableLayout dynamically in Android
Creating layouts using xml is easy. But creating layouts in runtime is the only option sometimes… TableLayout tableLayout = (TableLayout) findViewById(R.id.layoutTable); LinearLayout.LayoutParams tableRowParams = new LinearLayout.LayoutParams( LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT); /* create a … Continued
Java synchronized keyword : fixing Race condition
In a multithreaded Java program read and write operation from different thread at the same time creates race condition. The simple example here gives different output at different times: public class RaceCondition { public static void main(String[] args) throws InterruptedException{ final LongWrapper longWrapper = new LongWrapper(0L); … Continued
UML Quick Reference Guide
Allen Holub’s very useful and concise UML Reference Allen Holub’s UML Quick Reference
JavaScript based Android Game Development : Trump vs Chicken

Recently I have collaborated in an Android Game development with few of my friends which was named Trump vs Chicken. It was in javascript based on Phaser.js framework. Later we’ve used cocoon.io to port it to Android platform. Initially we’ve tested with cordova but it was sluggish. Maybe cordova is better for App development rather … Continued
ROS-TURTLEBOT Project Report
This is our semester TURTLEBOT-ROS report on motion control and navigation. The PDF should show up here, which might take a while: Download the PDF file . Controlling ROS Turtlebot from Android device: Android control video
My explanation of Cheryl’s Birthday: Singapore’s maths puzzle
This was the puzzle Because Albert knows the month June but he is not sure it is June 17 or June 18 but Albert knows that Bernard also doesn’t know, because if the date would be June 18 Bernard could tell it by now. Albert knows for sure that ONLY Bernard will not be able to tell … Continued