Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
dTub
Скачать

Armstrong Number Programs in Java using recursion | ISC Computer Science Class 11 & 12

Автор: Amplify Learning - with Alok

Загружено: 2019-07-30

Просмотров: 74689

Описание:

Design a class ArmNum to check if a given number is an Armstrong number or not. A number is said to be Armstrong if the sum of its digits raised to the power of length of the number is equal to the number.

Example:
371 = 33 + 73 + 13
1634 = 14 + 64 + 34 + 44
54748 = 55 + 45 + 75 + 45 + 85
Thus, 371, 1634 and 54748 are all examples of Armstrong numbers.

Some of the members of the class are given below:

Class name: ArmNum
Data members/instance variables:
n: to store the number.
l: to store the length of the number.
Methods/Member Functions:
ArmNum(int num): parameterized constructor to initialize the data member n = num.
int sumPow(int i): returns the sum of each digit raised to the power of the length of the number using recursive technique. E.g. 34 will return 32 + 42 (as the length of the number is 2)
void isArmstrong(): checks whether the given number is an Armstrong number by invoking the function sumPow() and displays the result with an appropriate message.

Specify the class ArmNum giving details of the constructor, int sumPow(int) and void isArmstrong(). Define a main() function to create an object and call the functions accordingly to enable the task.


You can follow/contact us here,

Facebook:   / alokmauryaofficial  
Twitter:   / alokmaurya95  
Instagram:   / alokmaurya95  

#AmplifyLearning #Computer

Armstrong Number Programs in Java using recursion | ISC Computer Science Class 11 & 12

Поделиться в:

Доступные форматы для скачивания:

Скачать видео mp4

  • Информация по загрузке:

Скачать аудио mp3

Похожие видео

Disarium Number in Java (using Recursion) | ISC Computer Science Class 11, 12

Disarium Number in Java (using Recursion) | ISC Computer Science Class 11, 12

Recursion in Java | Factorial, Power using Recursive Technique  | Computer Science Class 11, 12  ISC

Recursion in Java | Factorial, Power using Recursive Technique | Computer Science Class 11, 12 ISC

Output Questions based on Recursion | Very Important | ISC Computer Class 11, 12

Output Questions based on Recursion | Very Important | ISC Computer Class 11, 12

"please stop calling us slop" - Microslop

Я в опасности

Я в опасности

Computer Science Class 12 ISC Board | All Topics

Computer Science Class 12 ISC Board | All Topics

Inheritance in Java | How to do Inheritance Program? | Class 12 Computer ISC board

Inheritance in Java | How to do Inheritance Program? | Class 12 Computer ISC board

🔴 Propositional Logic | Computer Science

🔴 Propositional Logic | Computer Science

Recursion in Java | From Basic to Advanced | Class 11, 12 Computer Science

Recursion in Java | From Basic to Advanced | Class 11, 12 Computer Science

ICSE Computer Applications Class 10th | Amplify Learning - Learn ICSE Java

ICSE Computer Applications Class 10th | Amplify Learning - Learn ICSE Java

Automorphic Number in Java | Class 10 Computer

Automorphic Number in Java | Class 10 Computer

Palindrome Word - Java Program | Computer Science Sem-2 Specimen Paper 2022

Palindrome Word - Java Program | Computer Science Sem-2 Specimen Paper 2022

Recursion based Output Question | Most Important Questions | Class 12th Computer 2024 Board Exams

Recursion based Output Question | Most Important Questions | Class 12th Computer 2024 Board Exams

Number Programs based on Recursion | ISC Computer Science, Class 12th | Important Java Programs 2023

Number Programs based on Recursion | ISC Computer Science, Class 12th | Important Java Programs 2023

tagesschau in Einfacher Sprache 19:00 Uhr, 13.01.2026

tagesschau in Einfacher Sprache 19:00 Uhr, 13.01.2026

I Read Honey's Source Code

I Read Honey's Source Code

Class 10th - 45 Most Important MCQs 🔥 | Next Toppers

Class 10th - 45 Most Important MCQs 🔥 | Next Toppers

SPRAWDZAMY TELEFON DRUGIEJ OSOBIE! 📱🥺

SPRAWDZAMY TELEFON DRUGIEJ OSOBIE! 📱🥺

UCIEKAM PRZED STRASZNYM 67 w ROBLOX!

UCIEKAM PRZED STRASZNYM 67 w ROBLOX!

Ile zarabia STOLARZ? Leon ma 17 lat i własną stolarnię! | DO ROBOTY

Ile zarabia STOLARZ? Leon ma 17 lat i własną stolarnię! | DO ROBOTY

© 2025 dtub. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: infodtube@gmail.com