Skip to content

Commit dad0818

Browse files
Solution for Emirp Number
1 parent b4bbd1a commit dad0818

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Number Theory/Emirp.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public static void main(String args[]) {
2020
int d = x % 10;
2121
r = r * 10 + d;
2222
}
23-
for (int x = 2; x < n; x++) { // to check the reversed number for being prime or not
23+
for (int x = 2; x < r; x++) { // to check the reversed number for being prime or not
2424
if (r % x == 0) {
2525
emirp = false;
2626
break;

0 commit comments

Comments
 (0)