Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- *
- */
- /**
- * @author Ravinesh
- *
- */
- public class que6_LCM {
- /**
- * @param args
- */
- public static void main(String[] args) {
- // TODO Auto-generated method stub
- for (int i = 0; i <= 100; i++) {
- if ( i % 12 == 0
- && i % 15 == 0
- && i % 20 == 0
- && i % 27 == 0) {
- System.out.println(i);
- }
- else {
- System.out.println("There is no such number divisible by 12,15,20,27");
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment