Solved

Check if something is devisible by 11.

Posted on 2004-05-01
2
328 Views
Last Modified: 2006-11-17
Goodmorning,

I need to check the devisiblilty of a number by 11. It is to check if a bank account is valid or not.
How do I do that in an elegant manner in C#?

thanks
Marco
0
Comment
Question by:EnolaKotrotsos
2 Comments
 
LVL 15

Accepted Solution

by:
Timbo87 earned 125 total points
ID: 10970402
int acctNum = 99;
if(acctNum % 11 == 0)
     // number is divisible by 11
else
     // number is NOT divisible by 11
0
 
LVL 1

Author Comment

by:EnolaKotrotsos
ID: 10970412
Thanks Timbo. I totally forgot....
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now