DECLARE FUNCTION CONSO(N$)
CLS
INPUT"ENTER ANY WORD";N$
PRINT"TOTAL NO OF CONSONANT";CONSO(N$)
END
FUNCTION CONSO(N$)
C=0
FOR I=1 TO LEN(N$)
B$=MID$(N$,I,1)
C$=UCASE$(B$)
IF C$<>"A"ANDC$<>"E"ANDC$<>"I"ANDC$<>"C$<>"O"AND C$<>"U" THEN C=C+1
NEXT I
CONSO=C
END FUNCTION
CLS
INPUT"ENTER ANY WORD";N$
PRINT"TOTAL NO OF CONSONANT";CONSO(N$)
END
FUNCTION CONSO(N$)
C=0
FOR I=1 TO LEN(N$)
B$=MID$(N$,I,1)
C$=UCASE$(B$)
IF C$<>"A"ANDC$<>"E"ANDC$<>"I"ANDC$<>"C$<>"O"AND C$<>"U" THEN C=C+1
NEXT I
CONSO=C
END FUNCTION
No comments:
Post a Comment