How do you distinguish between numbers that are add and even in javascript? i searched a whole jscript book and web for it but couldn't find any info.

Recommended Answers

All 2 Replies

do an integer division by 2 and check if the modulo is 0.

P.S. you should really ask that in the Javascript/HTML forum, it's got nothing to do with JSP.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.