How to overcome this habit??? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 10

How to overcome this habit???

I'm learning C++ after learning python and because of this I feel a bit bored when I come in a situation where a particular task in C++ can easily be done using a function in python!!! How can I overcome this??? I know there are a lot of built-in functions in python and I'm used to it!!!! How to think like a C++ programmer???? https://code.sololearn.com/cbz7j3d4tsFl/?ref=app https://code.sololearn.com/ckVrxUy3GkUV/?ref=app

17th Mar 2019, 7:37 AM
Ayush Sinha
Ayush Sinha - avatar
8 Answers
+ 11
Writing code in C++ instead of Python comes at a price - it will take longer and require more thinking etc. So why would you even do it? That's the decisive question - what's your reason for using C++? You might want the better performance. So you can estimate for yourself: Is the increase in performance worth the increased trouble of coding?
17th Mar 2019, 11:59 AM
HonFu
HonFu - avatar
+ 10
HonFu, I think I should stick with python as it has gr8 scope in future and I feel a bit ease while coding with it. I think, in the end what matters is the product in your hand. And at the moment, I'm able to code with python very fast and easily!!! Talking about C++, well I think it should be in the language list of each and every programmer but not in the list of mine(as I'm only a school student for now and it's a bit challenging to learn it). Also, my studies may get affected if I move to learn this gigantic language, in which I have to learn a lot of stuff to write a very basic program. I love this language but for now I have decided to close it for now!!!!
17th Mar 2019, 1:01 PM
Ayush Sinha
Ayush Sinha - avatar
+ 9
HonFu, yep!!! So, if I wanna high performance in my code and want to code using python, then will it be that efficient? To be honest, I'm only a school student now and I don't even know which field of programming I want to go. I managed to get a very little time to open this app after completing my homework and studies, and after opening it I come across such type of things. Programming for now is not a big issue for me as I won't study it for the next 3-4 years!!! do you have any suggestions???
17th Mar 2019, 12:45 PM
Ayush Sinha
Ayush Sinha - avatar
+ 6
Habits are hard to break. Deal with your motivation to learn C++. Then read on Pomodoro, it may help you manage that habit
17th Mar 2019, 8:15 AM
Da2
Da2 - avatar
+ 2
Ayush Sinha, it is all very individual, so hard to give an advice about it. If you have no pressure and no specific aim, I would just concentrate on what's most fun and interesting, while making sure you don't forget what you've learned in the other language so far.
17th Mar 2019, 12:53 PM
HonFu
HonFu - avatar
+ 2
C++ doesn't go anywhere, you can get back to it anytime you feel like it. :)
17th Mar 2019, 1:13 PM
HonFu
HonFu - avatar
0
Relax and try to think of what you hope to achieve with both language that could help you to find which language to learn first
17th Mar 2019, 10:53 AM
George S Mulbah II
George S Mulbah II - avatar
0
Relax and try to think of what you hope to achieve with both language that could help you to find which language to learn first
17th Mar 2019, 10:53 AM
George S Mulbah II
George S Mulbah II - avatar