Skip to main content

100 days of code with Saroj Bhattarai

A few days ago, I saw "100 days of code" talk on YouTube. A girl over there was telling how it changed her life (Link at the bottom of this blog). So I decided to give it a try. I had a habit of quitting everything before finishing it. For this and most of all, I was unproductive in Lockdown due to Corona Virus. I wanted to utilize this time. So I went to 100 days of code website

I was motivated by the thought I wanted to do something, so I tweeted their tweet. Till that time I was unsure, what am I going to do? I just tweeted and wanted to figure it out what I would be doing. 

I thought for half an hour. Reviewing all of my coding skills I decided to do Android Projects. I have successfully completed my day 1. It was fun because I did study a little study and knew some of Android prior to coding. Check out my GitHub. I have shared my thoughts on the log of Day0. You can also find my log over there. 

I will write several other blogs what state am I at? How much did I improve? 

Follow me on Twitter: https://twitter.com/sarojofficial (For daily updates about 100 days of code)



Comments

Popular posts from this blog

How to get GitHub Student Pack, Apply now

Git is a version control system. GitHub is a web-based hosting service for version control using git. You can save all the projects on GitHub. GitHub has given some benefits for students. They recently are providing the student development pack for the students to give access to developers tools for free. Some of these real world tools are too expensive for a student to use. So, for those students who love the education, this could be just great! To get students developer pack, we are going to follow these steps:
1. First you need to make an account on GitHub. Go to this link https://www.github.com/ and sign up for free. 2. After making an account on GitHub, visit the link https://education.github.com/pack/.
3. Click on “Get your pack” button.  4.Sign with GitHub with your username and password.  5. Click on the button “Yes, I’m a Student”.
6. Enter your name and verify your academic status. Add a photo of your identity card where it says “Drop file here or click to upload”. 
7. Enter your C…

Basic guidelines for Chess opening.

If you are reading this blog, you probably know how the pieces move in the game of chess. The player with the white pieces always moves first. The opening is generally considered complete when your rooks are connected. There are some basic principles to follow how to play efficiently. We should focus on the development of pieces. Here are top 10 opening rules for good chess opening:
We must attack the center of board. So, OPEN with a CENTER PAWN like e4, d4. While (e4d4e5d5) are generally regarded as the central squares, the same principle can sometimes be extended to the adjacent squares like (c4c5d3d6e3e6f4f5).DEVELOP pieces with threats. Always develop your Knights before Bishops. Develop knights to towards the center of board rather than side of board. When the knight is developed in the center, it could attack up to 8 squares. The real reason to develop Knights before Bishops is that Knight are shorter-range pieces, and it will take them a couple of moves to ge…

How to write PROLOG program for half adder?

In this problem, we are going to implement some logic (of course it is all about logic) that will run calculate the half adder sum and carry. We know has two inputs, and it will give sum and carry which looks like this:





X            Y                 Sum                 Carry
0            0                  0                      0
0            1                  1                      0         
1            0                  1                      0
1            1                  0                      1


So, to implement sum we need XOR gate and to implement Carry we need AND gate.

Here is how we do it:

xORGate(0,0,0).
xORGate(0,0,0).
xORGate(0,0,0).
xORGate(0,0,0).


aNDGate(0,0,0).
aNDGate(0,0,0).
aNDGate(0,0,0).
aNDGate(0,0,0).

halfadder(X,Y,S,C):-xORGate(X,Y,S), aNDGate(X,Y,C). 

Now, you can run this code by giving the values of X and Y.
like this:
halfadder(1,1,S,C)  and the output will be
S=0
C=1