to learn programming (precisely programming in small), you need three things:
1. knowledge of data structure (eg array,linked list ,tree and
hash table are sufficient to a large extent)

2.knowledge of algorithm (eg searching(linear and binary) and sorting(merget sort etc) are sufficient

3. through knowledge of one programming language. I suggest to start with C.

For an overall view on programming a book called practice of programming by kernighan and pike is
very good in my opinion.