+ 3
How can i solve programming problems ?
6 Answers
+ 2
First break it into steps such as what you want. For example to print the sum of two inputted numbers
1 display a prompt asking user for numbers
2 take input
3 sum the numbers
4 display the numbers and their result
Then start coding it using sudo code:
count <<prompt;
cin << num1<<num2
Sum = num1 + num2
cout <<"the sum of ...
Then using the sudo code write the actual code using declarations such as
int num1. N
+ 4
You divide a problem into smaller probpems until you can solve those.
If you cant break it down and still cant solve it you have to ask more experienced programmers.
+ 1
Can i solve a programming problem without an algorithm, or it's necessary ?
+ 1
Every programm is an algorithm.
Or how would you define algorithm?
+ 1
If breaking it down isn't working, you can search StackOverflow.com for a solution to a similar problem.
+ 1
I mean by solving with an algorithm :
writing a pseudocode which contains the steps of the solution, and then converting it into the desired programming language Dragonxiv