Computer will predict your number after a while ;) So i just was bored and tired then I decided to improve my algorithm.
just want to say if you want to solve a programming problem you better try writing down the steps. I tried this and uploaded it here for you I hope you like the way I solve my stupid problem. I really like to share my experiences and it's just a stupid one.