Search This Blog

Monday, October 14, 2019

14. To Display reverse digit

CLS
INPUT "Enter any number"; N
S = 0

WHILE N <> 0
R = N MOD 10
S = S * 10 + R
N = N \ 10
WEND
PRINT "Reversed digits is "; S
END

15. To Display the given number is palindrome or not

CLS
INPUT "Enter any number"; N
A = N
S = 0
WHILE N <> 0
R = N MOD 10
S = S * 10 + R
N = N \ 10
WEND
IF A = S THEN
PRINT"the given number is palindrome"
ELSE
PRINT"the given number is not palindrome"
END IF

END

Sunday, October 13, 2019

16. To Display armstrong

CLS
INPUT "Enter a number"; N
A = N

S = 0
WHILE N <> 0

R = N MOD 10
S = S + R ^ 3
N = N \ 10
WEND
IF A= S THEN
PRINT "It is armstrong number";
ELSE
PRINT "It is not armstrong number";
END IF
END

17. To Display Prime or Composite

CLS
INPUT "ENTER ANY NUMBER"; N
C = 0
FOR I = 1 TO N
IF N MOD I = 0 THEN C = C + 1
NEXT I
IF C = 2 THEN
PRINT N; "IS PRIME NUMBER"
ELSE
PRINT N; "IS COMPOSITE NUMBER"
END IF
END

18. To Display Factor

CLS 
INPUT "Enter any number";N
FOR I = 1 To N
IF N MOD I = 0 THEN PRINT I
NEXT I
END

19. To Display Factorial number

CLS
INPUT "Enter any number";N
F = 1
FOR I = 1 To N
F = F * I
NEXT I
PRINT "Factorial number";F
END

20. To Display multiplication table

CLS
INPUT "Enter any number"; N
FOR I = 1 TO 10
PRINT N; " X " ; I ; " = " ; N * I
NEXT I
END

21. To Display 1,1,2,3,5,8....10th term

CLS
A = 1

B = 1
FOR I = 1 To 10
C = A + B
A = B
B = C
NEXT I
END

22. To Display 1,4,9,16......10th term

CLS
FOR I = 1 To 10

PRINTI^2
NEXT I
END

23. To Display 5,10,15,20........10th term

CLS
A = 5

FOR I = 1 To 10
PRINT A
A = A + 5
NEXT I
END

24. To Display 1,12,123,1234,12345

CLS
FOR I = 1 To 5
FOR J=  1 To I
PRINT J;
NEXT J

PRINT 
NEXT I
END

25. To Display 1,22,333,4444,55555

CLS
FOR I = 1 To 5
 FOR J = 1 To I
  PRINT I;
    NEXT J
  PRINT
 NEXT I
END

Monday, September 2, 2019

My Father

                                 My Father


Father is the one who make us happy,who support us and many more.So My father name is Chandra Lama.Chandra means moon.He is now 46 years old.He likes to play football,he even won the football  cup  in his young ages.He also like to drive a car.He is supportive and hard worker . He always like to sing in morning.He even has his own song written by him.He like to cook food specially meat because he make's delicious meat with soup.

My father is also an ideal person of my life. He is my real hero and my best friend ever. He always helps me a lot in my any difficulty. He is an internet marketing manager in a limited company in New Delhi. He is very famous person in his office as well as in the society because of his gentleness and politeness.He is very intelligent man and always helps others in their problems. He is the boss of my family and gives advice and instruction to every family member. He solves problems of the neighbours. My father is very kind-hearted person and my real hero and best friend. He always shares with me his all the bad an happy moments. He tells me that he discuss his all life events to me to give me experience and take right steps in the absence of him. My father is very lovely father of the world. He is my real hero, best friend, my inspiration and best person of my life I ever seen. He is the person who helps me a lot in getting prepared for the school, getting rise of the bed and getting my home work done well.