Write a program to print natural number from 10 to 20 when initial loop counter I is initialised to 0
Answers
Answer:
This lesson will focus more closely on writing code in a programming language. Once the code is written, it must be tested and debugged to make sure it works as intended.
Explanation:
Steps to write a program
- Understand the problem you are trying to solve
- suggest a solution
- Draw a flowchart
- Write the pseudocode
- Write the code
- Test and debug
- Test with real users
- Release program
- Repeat the steps for the next version
Computer code is basically a list of instructions that can execute a certain program. The code is written as plain text so that the compiler can read it. Compilers see formatting characters as syntax errors. The document is assigned a unique file extension that indicates the nature of the code. For example, a file created with Python is saved with a .py extension, such as 'myprogram.py'. However, the actual content of the file is still just plain text.
Since most of the code is in plain text, you can write the code using a basic word processor or text editor. However, it is much more efficient to use a software application that is specifically designed for coding in a particular language. For example, when you're writing a document in plain English, you'll use word processing software that can help you with things like formatting, spelling, and grammar. Similarly, the code editor provides tools such as syntax checking. Syntax is the codification of what spelling and grammar are to written English.
#include<stdio.h>
#include<conio.h>
void main()
{
int n;
clrscr();
printf("\n"); //for new line
// Do While Loop
do
{
printf(" %d",n);
n++; // Increment
}
while(n>=10)&&(n<=20); // Condition
getch();
}n=1; // Initialize
do
{
printf(" %d",n);
n++; // Increment
}
while(n>=10)&&(n<=20); // Condition
getch();
}
brainly.in/question/51962036
#SPJ2