Interview based on Leetcode questions… you are doing it wrong

I noticed a huge trend of interviewers, specially the young professionals using algorithms and problems discussed in Leetcode. There are people that studies months or even years all the exercises trying to pass in an interview most part of the time memorizing them.

Honestly, if you, the interviewer, you were hired because you took hours and hours resolving the problems from sites like Leetcode, congratulations!!! there is a huge chance you are another useless resource for your organization.

A lot of candidates they even know how to start a webserver, they do not know how a microcontroller works, how a RTOS works, or don’t know when to use a SQL or NoSQL database in a system. But do they know how to resolve an exercise where the little frog must to jump in N possible stones obeying a specific rules.

Let’s be honest.. if you are hiring someone to develop features in React… just ask the person questions that are relevant to the job, or even try to explore if this person has side project and what they are… That candidate that took months studying how the frog must to jump stones will not resolve your issues. Besides that, check the skillset and how you can use his/her skillsets in your product, check how the candidate work in a team, how he/she reacts for last minute changes, if it is able to understand how your system or product must work and the most important thing, if the developer has passion for his/her work. Does the algorithm you are asking to resolve will really tell us if the candidate is a good fit ?

There is NOTHING wrong with Leetcode. I am not against Leetcode because it is just a tool that helps us to exercise and understand different algorithms, and to chat ideas with the community and understand how to things can be resolved differently.

Please, go beyond Leetcode. Your employeer will be thankful in the future.


God does not play dice – chromosome, nucleotide and bits.

First of all this is not a technical post neither a computer science post. Also, this is not a religious topic. We will talk about chromosomes, nucleotide how this can make me think there is a God or expanding to our cosmos a possible “Architect of Universe”. I am enjoying a short vacation, thus I reserve myself the right to think in something else besides code.

Sometime ago I was doing a training in Python to explore and analyse DNA sequences. A very basic introduction to chromosomes but something beyond that class really intrigued me.

Each single cell in human body has 23 chromosome and each chromosome has 5 BILLION nucleotide.

Each nucleotide is composed by a base, a phosphate and a deoxyribose (sugar).

The base can be formed by 4 different elements:





As you can see, the variance in a nucleotide is the base. So if the base has 4 different options and each chromosome is composed until 5 billion nucleotide then

5 billion nucleotide x 4 = 20 billion of possible "bits"

20 billion possible bits in a nucleotide!!!! Continue reading

Running Processes When Your Screen is Locked Only Using C#

Imagine the following situation. You have a heavy process that execute some tasks not so important during your regular day. However, you would like to keep this processing running when your screen is locked and kill when your screen is unlocked.

A typical example is mining blockchains. Some cryptocoins like Monero can be mined using CPU .. yeah.. I know GPUs are better but mining Monero is still feasible using CPUs (specially Intel Xeon).

This is a very simple but useful software written in C# and runs as a hidden Windows console application in order to avoid any annoyance.

[sourcecode language=”cpp”]
using System;
using System.Diagnostics;
using Microsoft.Win32;
using System.Runtime.InteropServices;

namespace dws
class Program

static extern IntPtr GetConsoleWindow();

static extern bool ShowWindow(IntPtr hWnd, int nCmdShow);

const int SW_HIDE = 0;
const int SW_SHOW = 5;

private static SessionSwitchEventHandler sseh;

static void Main(string[] args)

var handle = GetConsoleWindow();
ShowWindow(handle, SW_HIDE);

sseh = new SessionSwitchEventHandler(SystemEvents_SessionSwitch);
SystemEvents.SessionSwitch += sseh;

while (true) {


static void SystemEvents_SessionSwitch(object sender, SessionSwitchEventArgs e)
if (e.Reason == SessionSwitchReason.SessionLock)
//desktop locked
else if (e.Reason == SessionSwitchReason.SessionUnlock)
//desktop unlocked


private static void startMiner()

Process process = new Process();
process.StartInfo.FileName = "your_process.exe";
process.StartInfo.Arguments = "your_arguments";
process.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;


private static void killProcess()
foreach (Process proc in Process.GetProcessesByName("your_process"))
catch (Exception ex)


How hack the Android boot.img with no compilation


There are two very cool tools (unmkbooting and mkbootimg) that allows you to hack your boot.img and make changes in the ramdisk including the init.rc very quickly and faster than compilation. You actually do not need to compile anything, just using a Linux machine (I am using Ubuntu 12.04 64bits), install the two tools and run the procedure below:

  • Install install these two tools in your linux machine:


and them,

Continue reading



DBASEII and Mr. SPOCK: Today we lost our first officer Mr Spock leaving definitely the Enterprise star-ship but not our hearts. Few people really knows the importance of Mr Spock on influencing our modern databases. In 1979, a programmer called Wayne Ratlif created a database that could accept common English words like “find”, “insert”, “append”, “browse”, etc.. Wayne worked for Jet Propulsion Laboratories in Pasadena.

It was possible also to display messages in the screen creating menus, print data and have real applications trying to bring the natural manner that Mr Spock accessed data in the sophisticated Enterprise. The database received the name of Mr. Spock home planet, in other words, Vulcan. Later the software turns commercial and it was renamed as DBASEII even not having a first version… Vulcan or DBASEII was able to run in 24KRAM computers based on Z80 processor until huge main frames and introduced a modern database management even not being a full relational database. I worked with “Vulcan” database when I was 13 years old creating an application for storage control. I am thankful for all inspiration that Mr Spock brought during decades to our lives and our technology.

R.I.P. Mr Spock or Leonard Simon Nimoy and thanks for all!!!

(March 26, 1931 – February 27, 2015)

Installing OpenGrok and Tomcat 7 on Ubuntu 13.04 quickly

If you are a developer you need a good source code navigator. I have used cscope to navigate and edit code directly from my terminal dismissing any graphical user interface but some people like to use the sourcenav or net beans ecosystem. However both are graphically nice but are “heavy” apps and also, if you want to share a way with your co-workers how to browser your code you will need to install the apps in different desktops.

But what about to have a fast way to navigate in your code, have fast crossed references  and share your source code with your co-workers dismissing the installation of source navigators on different desktops using your web browser ?

If you need something like this or if you wants a fast and easy installation of a good source navigation, I recommend OpenGrok. To be honest, even if I do not need to share my code with anyone, I use in my machine only for my personal code browsing.

OpenGrok runs as a webapp that means you and your co-workers can use your favorite browser navigator. Chrome, Firefox, Internet Explorer, whatever! you only need your preferable one to enjoy the code.

Considering OpenGrok is web based you will need to install a web server to be used as servlet server. OpenGroks supports Tomcat or Glassfish.

I am personally using tomcat 7 in my ubuntu 13.04. Let’s see the 3 basic steps:

Continue reading

How to download quickly the kernel source code used on your Ubuntu

I am really sorry if this post is so shot and newbie but I will use these instructions on my next posts.

Try typing:

#> sudo -i

#> cd /usr/src

#> apt-get source linux-image-$(uname -r)

If fails complaining about dpkg-source, you need the debian package development tools.

Install it doing:

#> apt-get install dpkg-dev

and try to download the source again.

You can get using git. If you prefer this method check this page.

I am using root (sudo -i) on this example because next post I will compile some code that requires the right permission to run the example codes.

I love a Duck! Why DuckDuckGo search engine is better than Google ?

I am kind of person – or alien as they call me in USA even being from Brazil not Mars :), that usually try different ways to improve how I study or work. I am using a new search engine and I am really loving it! Click in and try yourself.

Why DuckDuckGo ?

The quality of results and how you can filter are much more better than google search engine. Google already recognized them as a real competitor and looks like Mr Larry Page not dared to say “really bad job” as he did with new facebook graphic search.

Done based in github, perl5 and other open softwares, I will tell you why this search really rocks!

What they do ?

  1. do not track you !! it means privacy! Your personal information is safe!
  2. do not use bubble-filter !! Oh yeah this really makes different because I can have different type of results not based what the system “think” compatible with my profile
  3. They have a feature called !bang. Bangs are very cool.. if you wanna have all searches in a specific site you only add “!” following the site.. for example if you type in the search box “stamps!ebay” the search goes directly to ebay showing the search you did!!! The same can be done with facebook, amazon, and multiples sites.. some sites you have option to use bang with few words, for example, you can use “asus!a” to search in amazon.
  4. When you make a search if have a list with results and in front of each link there is a icon related to the site you searched. If you click in the icon instead the link, the engine re-searches and give you more results related to that site!
  5. There is not “NEXT PAGE”.. Only scroll and the new searches will be automatically loaded


My name is Manoel Ramon and I am addicted in software programming… this first post is a testimony about myself…

I was something around 10 years old when my cousin broke up with her boyfriend and he decided to try to reconnect with her thru me… well.. bad mistake 🙂
He showed up in my home with a personal computer.. it was a TK85 with amazing ROM 8Kb and RAM 16Kb based in Z80 processor… I could see loading programs using a regular tape (cassette) using a tape player and some wires..

After some minutes, the computer loaded a game in my TV !!! That was really cool!!! So, he left the computer with me and I started to read a BASIC MANUAL.

This was the first problem of my life:

[sourcecode language=”css”]
20 GOTO 10

Then I typed “RUN” following ENTER

After this… I was totally addicted.. See the machine doing something that I created was fantastic.. Then, every morning I woke up at 7:00AM to watch a TV series called “Bits & Bytes” in the TV Cultura Brasil. This was a canadian TV series teaching people what is a personal computer, a processor, a interpreter, a computer program, how the memory works, etc.

After couple years I bough a revolutionary micro-computer called HOTBIT MSX Continue reading