Escolar Documentos
Profissional Documentos
Cultura Documentos
In this program we will read a positive integer number and then calculate product of all
digits using a class. For example, if input number is 12345 - sum of all digits, product of all
digits will be 15 , 120
120.
Copy
Ads help us run this site
//Java program to find sum and product of all digits using class.
When you visit our site, pre-selected Manage Your Choices Continue to site
companies
import may access*and
java.util.* ; use certain
information on your device and about this
site to serve relevant ads or personalized
class
content.DigitsOpr
{
Information
privatethatintmay be used
num;
Purposes for storing information
Output:
Enter an +ve integer number:1234567
SUM of all digits: 28
PRODUCT of all digits: 5040
Object as an Array in
Java
includehelp.com
JavaScript code to
check whether a...
includehelp.com
Python | Program to
print Odd and Even...
includehelp.com
Minimum swaps
required to sort an...
includehelp.com
Midpoint Circle
Algorithm
includehelp.com
Ad
1. Basic Java Programming
2. Basic Java Programs Asked in Interviews
3. Beginner Java Program
Name
ALSO ON WWW.INCLUDEHELP.COM
Capitalize first and last letter of each word in as header file in C++
a line 2 comments • 6 months ago
3 comments • 6 months ago IncludeHelp — Thanks Debasis Jana (Bappa)
Mirko Schmidt — Thanks for your reply! This Avatarfor pointing the typo mistake - I have fixed it.
Avatarfor-loop is meant to replace the first for-loop in Keep visiting and …
your code, so "i" is the …
✉ Subscribe d Add Disqus to your siteAdd DisqusAdd 🔒 Disqus' Privacy PolicyPrivacy PolicyPrivacy
ABOUT SECTION
» About us
» Contact us
» Feedback
» Privacy policy
STUDENT'S SECTION
» Internship
» Certi cates
» Content Writers of the Month
SUBSCRIBE
» Facebook
» LinkedIn
» Subscribe through email