Posts

Showing posts from March, 2015

Another Brick on the Wall

The first thing that comes into my mind after i find any app with security, encryption, locked features etc, is that whether it can be tweaked and to get the paid features. Since 1 or 2 months back an app attracts me. But due to my laziness i hadn't given enough time to it in past. But tonight i decide to give it a serious try. I sit on computer with the apk of that application on hand. For every app my first try is to look at the app's private directory and check whether i could find any interesting information hidden on database or on preferences file. But this very app has nothing of this type. That's why this need a serious try. I have the apk means i have the source code. All i need to do is extract the apk and then convert the .dex file to .jar package. After this the story goes easy cause that jar package can easily be converted to a zip file full of source code. Yahoooooo. Then starts slightly extensive task. I have to go through the source code and then find fu...

"Sward on Circle" Riddle

After one of my friend pointed me this question. I become curious to solve it by programming logic. And just after i got to my computer i started the vi editor and started to write a program to find the solution. I just tried to simulate the real game situation. And comeup with following code. #include <stdio.h> #include <stdlib.h> struct player { struct player *prev; struct player *next; int roll; }; int main(){ int i=0; int j=100; int count=0; struct player* players[100]; for(i=0;i players[i] = (struct player*) malloc(sizeof(struct player)); players[i]->roll=i+1; } for(i=0;i players[i]->next = players[(i+1)%100]; // players[i]->prev = players[(i+99)%100]; } struct player* head = players[0]; struct player* nextHead; count = 0; while(1){ if(head == head->next->next){ printf(" I am the winner %d\n",head->roll); break; } count ++; printf(" %d ",head->next->roll); nextHead = head->next->next; head->next = nextHead; ...