10/11/2020 0 Comments Gw Basic Online
Reply Delete RepIies Reply Hafiz Juné 10, 2018 at 4:54 AM by using read and data stament in gw basic Reply Delete Replies M.Daniyal yousaf October 5, 2018 at 3:50 AM 10 cls 20 for I 1 to 5 30 read x 50 print x 60 next I 70 data,,,, 80 end Delete Replies Reply M.Daniyal yousaf October 6, 2018 at 7:28 PM Open this link to see the snapshot of the code in action Delete Replies Reply Reply Abdullah June 23, 2018 at 12:39 PM can anyone tell me the program to print the smallest number using fornext statement and also using only one input statement Reply Delete Replies Reply Khursheed Fateh July 23, 2018 at 3:55 PM Smallest number out of what Reply Delete Replies Reply Khursheed Fateh July 24, 2018 at 6:31 AM This comment has been removed by the author.Program: 10 CLS 20 FOR B 2 TO 40 STEP 2 30 PRINT B 40 NEXT B 50 END Algorithm Step 1 START Step 2 STORAGE B2 Step 3 DECISION IS B NOT THEN GO TO STEP 7 Step 4 COMPUTE BB2 Step 5 PRINT STEP 6 GOTO STEP 3 Step 7 END Algorithm Step 1 START Step 2 INPUT L, W Step 3 COMPUTE AREA L W Step 4 PRINT AREA Step 5 END Practical: 11: Write a program that can calculate the perimeter of the rectangular.Program: 10 CLS 20 INPUT Length;L 30 INPUT Width; W 40 PERIMETER 2 ( LW) 50 PRINT PERIMETER.; PERIMETER 60 END Algorithm Step 1 START Step 2 INPUT L, W Step 3 COMPUTE PERIMETER 2 ( LW) Step 4 PRINT PERIMETER Step 5 END Practical: 12: Write a program that can calculate the square and cube of any number.Program: 10 CLS 20 INPUT Enter any No.; N 30 Sq NN 40 Cub N3 50 PRINT Square.; Sq 60 PRINT Cube.; Cub 70 END Algorithm Step 1 START Step 2 INPUT N Step 3 COMPUTE Sq NN Step 4 COMPUTE Cub N3 Step5 PRINT Sq,Cub Ste Practical: 13: Write a program that can convert temperature from Centigrade to Fahrenheit Program: 10 CLS 20 INPUT Temperature in Centigrade:; C 30 F 95 C32 40 PRINT Temperature in Fahrenheit; F 50 END Algorithm Step 1 START Step 2 INPUT C Step 3 COMPUTE F 95 C32 Step 4 PRINT F Step 5 END Practical: 14: Write a program that can convert temperature from Fahrenheit to Centigrade Program: 10 CLS 20 INPUT Temperature in Fahrenheit:; F 30 C 59 ( F-32) 40 PRINT Temperature in Centigrade; C 50 END Algorithm Step 1 START Step 2 INPUT F Step 3 COMPUTE C 59 ( F-32) Step 4 PRINT C Step 5 END Practical: 15: Write a program that can draw a Triangle.
Gw Basic Online Code In ActionProgram: 10 CLS 20 SCREEN 2 30 LINE (70,80)- (190,170),,B 40 END Algorithm Step 1 START Step 2 PRINT SCREEN 2 Step 3 OUTPUT LINE (70, 80) - (190,170),, B Step 4 END Practical: 17: Write a program that can add 15 3020325. Program: 10 CLS 20 READ A,B,C,D 30 SUM ABCD 40 PRINT SUM OF 15,30,20 AND 325 IS; SUM 50 DATA 15,30,20,325 60 END Algorithm Step 1 START Step 2 STORAGE A1 Step 3 DECISION IS A Step 4 COMPUTE AA1 Step 5 COMPUTE SUM SUM 5A Step 6 PRINT 5A, SUM Step 7 GOTO STEP 3 Step 8 END Practical: 18: Write a program that can print all odd numbers from 1 to 100. Program: 10 CLS 20 FOR N 1 TO 100 STEP 2 30 PRINT N 40 NEXT N 50 END Algorithm Step 1 START Step 2 STORAGE N1 Step 3 DECISION IS N Step 4 COMPUTE NN2 Step 5 PRINT N Step 6 GOTO STEP 3 Step 7 END Practical: 19: Write a program that can print all even numbers from 2 to 100. ![]() Program: 10 CLS 20 FOR N 1 TO 5 30 PRINT GOD IS GREAT 40 NEXT N 50 END Algorithm Step 1 START Step 2 STORAGE N1 Step 3 DECISION IS N Step 4 PRINT GOD IS GREAT Step 5 COMPUTE NN1 Step 6 GOTO STEP 3 Step 7 END Practical:2:Write a Program to add two numbers. ![]() Algorithm Step 1 START Step 2 INPUT N1, N2, N3, N4, N5, N6 Step 3 COMPUTE AVG( N1N2N3N4N5N6) 6 Step 4 PRINT AVG Step 5 END Practical: 4: Write a program which can find the largest number of given three numbers. Algorithm Step 1 START Step 2 INPUT N1, N2, N3 Step 3 DECISION IS N1 N2 AND N1 N3 IF YES THEN PRINT N1 Step 4 DECISION IS N2 N1 AND N2 N3 IF YES THEN PRINT N2 Step 5 ELSE PRINT N3 Step 6 END Practical: 5: Write a program that can calculate the sum and average of four numbers. Algorithm Step 1 START Step 2 INPUT N1, N2, N3, N4 Step 3 COMPUTE SUM N1, N2, N3, N4 Step 4 COMPUTE AVG SUM4 Step 5 PRINT SUM,AVG Step 6 END Practical: 6: Write a program that can draw a circle in a square. Algorithm Step 1 START Step 2 INPUT NR Step 3 COMPUTE AREA 3.14RR Step 4 PRINT AREA Step 5 END Practical: 8: Write a program that can draw a circle. Program: 10 CLS 20 SCREEN 2 30 CIRCLE ( 100,100), 50 40 END Algorithm Step 1 START Step 2 PRINT SCREEN 2 Step 3 PRINT CIRCLE (1000,100),50 Step 4 END Practical: 9: Write a program that can find the value of a solid cylinder Algorithm Step 1 START Step 2 INPUT R, H Step 3 COMPUTE VOL 3.14R2H Step 4 PRINT VOL Step 5 END Practical:10: Write a program that can calculate the area of a rectangle Practical:11: Write a program to show 1st ten odd numbers using while wend loop. Reply Delete RepIies Reply Khursheed Fatéh February 5, 2017 at 10:35 PM I really like GW-BASIC and your blog took me back in time when I started learning GW-Basic. Reply Delete RepIies Reply Unknown ApriI 7, 2017 at 12:06 PM Too Good Reply Delete Replies Reply Asma Qureshi July 8, 2017 at 2:08 AM Good GW Basic this is the very 1st programming language when i started learning programming i was as grad 5. Reply Delete RepIies Reply Unknown 0ctober 23, 2017 at 8:53 PM kindly some one share the program to get full name of any person and return the number of characters in his first name. Reply Delete RepIies Khursheed Fateh Máy 15, 2018 at 2:08 PM 10 N 20 FN 30 D 40 DI 0 50 PRINT Enter your full name:; 60 INPUT N 70 N TRIM(N) 80 IF N THEN GOTO 200 END IF 90 DI INSTR(N, D) 100 IF DI 0 THEN 110 FN N 120 ELSE 130 FN MID(N, 1, DI) 140 END IF 150 PRINT Number of characters in your first name; 160 PRINT FN; 170 PRINT; 180 PRINT LEN(FN) 190 GOTO 10 200 END Delete Replies Reply Khursheed Fateh May 15, 2018 at 2:11 PM I posted above code thinking some visitor may need it. I used foIlowing site for tésting above code ánd there it wás working fine. Delete Replies RepIy Abdullah June 23, 2018 at 12:41 PM Mr.Khursheed can you tell me the program to print the smallest number using fornext statement and also using only one input statement Delete Replies Reply Khursheed Fateh July 23, 2018 at 3:53 PM Smallest number out of what Delete Replies Reply M.Daniyal yousaf October 6, 2018 at 2:44 AM This comment has been removed by the author. Gw Basic Online Free Short Courses24Delete Replies RepIy M.Daniyal yóusaf October 6, 2018 at 2:46 AM 10 cls 20 input enter your full name:,nm 30 nl len(nm) 40 fl 0 50 for I 1 to nl 60 sc mid(nm,I,1) 70 if sc then 90 else fl fl 1 80 next I 90 print first name legth;fl 100 end Delete Replies Reply M.Daniyal yousaf October 6, 2018 at 2:52 AM On 90 I have mistakenly type legth instead of length But program still work fine because It is just a prompt string dialog Delete Replies Reply M.Daniyal yousaf October 6, 2018 at 7:24 PM Open this link to see the snapshot of the code in action Delete Replies Reply Sheraz Ali Mughal September 22, 2019 at 10:57 AM Lear Short courses free Short Courses24 Delete Replies Reply Reply javed January 16, 2018 at 3:59 AM for further lectures please contact 0333 3322391 Reply Delete Replies Reply Unknown February 17, 2018 at 8:50 AM FLS Reply Delete Replies Reply Anonymous February 19, 2018 at 2:18 AM Hi u were shaded my life did u feel us another start i faded was it all my fantsy Reply Delete Replies rakhshi May 7, 2018 at 10:07 AM This comment has been removed by the author. Delete Replies RepIy Reply Hamza Fébruary 28, 2018 at 4:12 AM This comment has been removed by the author. Reply Delete RepIies Reply rakhshi Máy 7, 2018 at 10:06 AM This comment has been removed by the author.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |