
write a program to print '*' in a circular form?

Java Print Circle using Aestricks
public class PrintCircle {
public static void main(String[] args) {
int n = 5;
for (int i = -n; i <= n; i++) {
for (int j = -n; j <= n; j++) {
if (i*i + j*j <= n*n) System.out.print("* ");
else System.out.print(" ");
}
System.out.println();
}
}
}
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.