answersLogoWhite

0

I assume you mean for any n get surrounding 1s, 2s, 3s and so on till the particular n is in center.

Try analyzing quarter by quarter. So, we need 4 counting variables - i, j, x, y.

User Avatar

Anonymous

4y ago

What else can I help you with?

Related Questions

Write a unix program to print print a pattern?

echo 'print a pattern'


How do you display 1 11 111 1111 11111 in qbasic using FOR.NEXT?

cls a =1 for i = 1 to 5 print a; a = (a*10)+1 next i end


What is the most common lip print?

type II pattern or branching pattern is the most common pattern


To write shell program to check the given number and its reverse are same?

echo "enter the number" if [ $# -ne 1 ] then echo "Usage: $0 number" echo " I will find reverse of given number" echo " For eg. $0 12321, I will print 12321" exit 1 fi n=$1 rev=0 sd=0 while [ $n -gt 0 ] do sd=`expr $n % 10` rev=`expr $rev \* 10 + $sd` n=`expr $n / 10` done echo "Reverse number is $rev"


How do you generate patterns in gw basic?

write the following on gw basic in capital 10 rem "to print a pattern" 20 cls 30 print tab(30) * 40 print tab (29)*** 50 print tab (28)***** 60 end 70 run and there will be a pattern


Write a c program to print the following pyramid 1 121 1231 12321 1234321?

To print the given pyramid pattern in C, you can use nested loops. The outer loop controls the rows, and the inner loop controls the numbers to be printed in each row. Here's a simple C program to achieve this: #include <stdio.h> int main() { int rows = 5; for (int i = 1; i <= rows; i++) { for (int j = 1; j <= i; j++) { printf("%d", j); } for (int j = i - 1; j >= 1; j--) { printf("%d", j); } printf("\n"); } return 0; } This program will output the desired pyramid pattern.


What happens after the pattern of an individual print has been matched?

After the pattern of an individual print has been matched, it can be used for identification purposes, such as in forensic investigations or security access systems. The matched print can then be compared against other prints in a database to determine a potential match or identity of the individual.


What pattern is on the gloves Rosalie wears in the kitchen?

The gloves that Rosalie wears in the kitchen have a floral pattern.


How can you paint your bike zebra print?

The best way and the easiest way to do this is to print off a zebra print pattern, cut out the black parts and to use the rest, hold the paper up to your bike and spray black over it,creating zebra print!


Pattern skinny pants?

im wearing leopard print skinnies ATM :]


What is Niall Horans favorite pattern?

I am pretty sure it is zebra print if that is what you meant


If you want to print off a recipe or knitting pattern off a blog how do you get just what you want to print and not the whole blog?

Try and find a "Print" version of the post you'd like to print. If the blog doesn't offer one then the best is to clickthrough the specific post and only try and print that page. You can also try and select the area you'd like to print and in the print window choose to print only the selected area.