That's like saying if you know a foreign language very well,more automatically smarter evenif you have an F in English
No, it's not. Foreign languages do not excercise logos when you utilize them, computer programming does. Also, grades have little to no correlation with intelligence.
Even if it does require more "logical thinking" doesn't necessarily mean you have increased intelligence
As I literally just said, it does.
Being highly logical is directly correlative to being intelligent, so yes, knowing how to program does make you more intelligent.