Wap to display 1,2,3,5,8, up to 13th term DECLARE SUB SERIES ( ) CLS CALL SERIES END SUB SERIES A = 1 B = 2 FOR I = 1 TO 13 PRINT A; C = A+B A = B B = C NEXT I END SUB
Posts
Showing posts from October, 2019
- Get link
- X
- Other Apps
Wap to erase vowels from given string DECLARE FUNCTION ERA(A$) CLS INPUT"ENTER ANY STRING";A$ PRINT"STRING WITHOUT VOWELS =";ERA(A$) END FUNCTION ERA(A$) FOR I = 1 TO LEN (A$) B$=MID$(A$,I,1) C$=UCASE$(B$) IF C$<>"A" AND C$<>'E" AND C$<>"I" AND C$<>"O" AND C$<>"U" THEN D$=D$+C$ END IF NEXT I ERA=D$ END FUNCTION
- Get link
- X
- Other Apps
Wap to check the character is capital or small DECLARE FUNCTION CHECK$(A$) CLS INPUT"ENTER ANY CHARACTER";A$ PRINT"THE ENTERED CHARATER IS"; CHECK$(C$) END FUNCTION CHECK$(A$) C = ASC(A$) IF C>=65 AND C<=91 THEN CHECK$="UPPER CASE" ELSEIF C>=97 AND C<=122 THEN CHECK$="LOWER CASE" ELSE CHTR$="NOT A CHARACTER" END IF END FUNCTION
- Get link
- X
- Other Apps
Wap to find the palindrome word DECLARE FUNCTION REV$ (S$) CLS INPUT "ENTER ANY STRING"; S$ P$ = S$ IF P$ = REV$(S$) THEN PRINT "THE GIVEN WORD IS PALINDROME " ELSE PRINT " THE GIVEN NO. IS NOT PALINDROME" END IF END FUNCTION REV$ (S$) FOR I = LEN(S$) TO 1 STEP -1 B$ = MID$(S$, I, 1) W$ = W$ + B$ NEXT I REV$ = W$ END FUNCTION
- Get link
- X
- Other Apps
Wap to count total no. of consonant in given word DECLARE FUNCTION COUNT(N$) CLS INPUT"ENTER ANY STRING";N$ PRINT"TOTAL NO. OF CONSONANTS";COUNT(N$) END FUNCTION COUNT(N$) FOR I = 1 TO LEN(N$) B$ = MID$(N$,I,1) C$ = UCASE$(B$) IF C$<>"A" OR C$<>"E" OR C$<>"I" OR C$<>"O" OR C$<>"U" THEN C= C+1 NEXT I COUNT = C END FUNCTION
- Get link
- X
- Other Apps
Wap to count total no. of vowels in a word DECLARE FUNCTION COUNT(N$) CLS INPUT"ENTER ANY WORD";N$ PRINT"TOTAL NO. OF VOWELS IS";COUNT(N$) END FUNCTION COUNT(N$) FOR I = 1 TO LEN(N$) B$ = MID$(N$,I,10 C$ = UCASE$(B$) IF C$="A" OR C$="E" OR C$="I" OR C$="O" OR C$="U" THEN C=C+1 NEXT I PRINT"TOTAL NO. OF VOWELS =";C END SUB