Number-Guessing Game

A simple casino game made in C++

The popularity of casino games nowadays is undeniable, as online casinos have slowly made their way into new territories. In the US, three states have already declared online gambling to be legal, prompting casino mogul Sheldon Adelson to declare war against this highly lucrative industry.

The liberalization of online casino gaming in countries other than the U.S. has paved the way for safer, more efficient transactions, encouraging people to play online more. When InterCasino — the world’s first online casino website — launched, people didn’t have to worry about bringing loads of cash into brick-and-mortar establishments just to play slots or table games. Of course, legislation is still strict, especially for slot manufacturers looking to do business in countries with strict gaming regulations, but one thing remains clear: casinos and casino games are popular in many countries, and anyone looking to create fun programs can try making a simple casino game with C++.

This game is more of a number-guessing game, which can be likened to a barebones game of Roulette. Players make initial deposits before choosing a number from 1-10, and then entering the amount of money they wish to bet on the round. The program then picks a number from 1-10, and if the number matches the number given by the player, then the player wins 10 times the amount of money he has bet. Not getting the write number, however, will result in the player losing his betting money. There is no end to the game, and players can continue playing for as long as they want.

Remote Desktop with SSH Tunneling

Screenshot from 2014-11-04 16:54:14

One of my client’s requirement is to have a Ubuntu server with a Desktop Environment. Once in a while he will call me up to look at some problem he is having with one of his GUI based application. Its not always possible for me to be physically be there to see what the problem is, so I use a trick that have saved me many times in the past. Its simply a remote desktop with SSH Tunneling, its very simple and easy to set it up. As the name suggest you will need SSH access for this to work.

First you will have to install x11vnc on the remote desktop that you are trying to log in to sudo apt-get install x11vnc and then create a tunnel using SSH ssh user@ip_address -L 5900:localhost:5900 "x11vnc -display :0 -noxdamage" now you can use a VNC client like ‘Remote Desktop Viewer’ to connect to localhost:5900 and you should be able to access your remote desktop. The quality of the display may or may not be ideal but its still simpler and quicker than setting up 100 firewall rules for a VNC server or setting up teamviewer.

Give it a try and let me know how it went.

New Poll: How do you feel about NSA revelations by Edward Snowden?

NSA whistle blower Edward Snowden recently commented on how he feels that his mission has been accomplished. He said that he didn’t want to directly change the government, he wanted to give the public the information in order for them to make a choice. Now it is up to the citizens of the respective countries to decide whether they want to live in the status qua or they are going to start a movement for change.

I agree with Snowden on this. Before NSA revelations we only had a vague understanding on how deep the spying rabbit hole goes, thanks to Snowden, now the picture is much more clear. But there is also a group of people who honestly believes that the recent revelations shouldn’t come as a surprise to people who cared about privacy in the first place. There is a long history of NSA and other spy agencies spying on their citizens that has been made public in the past and nothing has changed since then.

Either way, I would love to know what you think. Started a new poll. If you are reading this from RSS, you will have to go to the site to view the poll on the sidebar. Feel free to share your opinion in the comment section.

Geeky Quote #11

What schools should refuse to do is teach dependence. Those corporations offer free samples to schools for the same reason tobacco companies distribute free cigarettes to minors: to get children addicted. They will not give discounts to these students once they’ve grown up and graduated.

– Richard Stallman

Page 1 of 1812345...10...Last »
space invader