9 Nov 2013

BASIC program-3

to calculate 2 numbers

10 CLS
20 let a=30 : b=36 :c=a+b
30 print c
40 end

output
66

BASIC program-2

to display the bio data


10 rem to display bio-data of a student
20 print "name: Siva"
30 print "class:VI-A"
40 print "roll no: 1"
50 end
output
name: Siva
class:VI-A
roll no: 1

BASICprogramming


 first program of BASIC



10 REM "my first Q basic program"
20 PRINT"sivarajan"
30 END
output
sivarajan
note: download  Q  basic to write this program

c ++for c++ programmers

for finding the number <,>or =

#include "iostream.h"
#include "stdio.h"

void main( );
{
icin>>a
 cin>>b

if (a>B)
{
cout<<"greatest no =",a;
}
else if   (a<b)
{
cout<<("greatest no = ",b;
}
else if   (a=b)
{
cout<<"all are equal ";
}
else
{
cout<<"wrong input"
getchar( );
}
output
23
34
greatest no=34