{"id":"28159e68-19e0-4dd1-914f-797332040dcd","name":"Pattern 10","description":"1. You are given a number n.\r\n2. You've to create a pattern of * and separated by tab as shown in output format.","inputFormat":"A number n","outputFormat":"<img src=\"http://pepcoding.com/resources/ojquestionresource/images/pat101.JPG\" alt=\"pat101\">","constraints":"1 &lt;= n &lt;= 100\r\n Also, n is odd.","sampleCode":{"cpp":{"code":"#include <iostream>\r\nusing namespace std;\r\n\r\nint main(int argc, char **argv){\r\n int n;\r\n cin >> n;\r\n\r\n //write your code here\r\n \r\n}"},"java":{"code":"import java.util.*;\r\n\r\npublic class Main{\r\n\r\npublic static void main(String[] args) {\r\n Scanner scn = new Scanner(System.in);\r\n\r\n // write ur code here\r\n\r\n }\r\n}"},"python":{"code":"import math\n\nn = int(input())\n# write ur code here"}},"points":10,"difficulty":"easy","sampleInput":"5","sampleOutput":"\t\t*\t\r\n\t*\t\t*\t\r\n*\t\t\t\t*\t\r\n\t*\t\t*\t\r\n\t\t*\t","questionVideo":"https://www.youtube.com/embed/X90L33S2xk0","hints":[],"associated":[{"id":"15a7dde1-37b8-4031-9cb2-0272123d128b","name":"What will be initial value for inner space? (Pattern 10)","slug":"what-will-be-initial-value-for-inner-space-pattern-10","type":4},{"id":"782b5dc1-0fa6-4fcf-a2dc-1e24e98e9412","name":"What is the order of printing the desired pattern 10?","slug":"what-is-the-order-of-printing-the-desired-pattern-10","type":4},{"id":"93477623-757f-4008-86f9-60d79daf206a","name":"What will be the initial value for outer spaces (pattern 10)?","slug":"what-will-be-the-initial-value-for-outer-spaces-pattern-10","type":4}],"solutionSeen":false,"tags":[],"meta":{"path":[{"id":0,"name":"home"},{"id":"0c54b191-7b99-4f2c-acb3-e7f2ec748b2a","name":"Data Structures and Algorithms","slug":"data-structures-and-algorithms","type":0},{"id":"ca241a91-e685-4c63-9d83-892cf12c5576","name":"Patterns","slug":"patterns-9997","type":0},{"id":"d61735fd-d194-4ada-bcad-9f7cbae0c6cf","name":"Pattern 10","slug":"pattern-10","type":1}],"next":{"id":"800a8209-4537-4dfa-90e5-7cdaa2107fa2","name":"Pattern 10","type":3,"slug":"pattern-10"},"prev":{"id":"056d8563-af67-4b12-b86d-8d871b9921d2","name":"Pattern 9","type":3,"slug":"pattern-9"}}}

Pattern 10

1. You are given a number n. 2. You've to create a pattern of * and separated by tab as shown in output format.

{"id":"28159e68-19e0-4dd1-914f-797332040dcd","name":"Pattern 10","description":"1. You are given a number n.\r\n2. You've to create a pattern of * and separated by tab as shown in output format.","inputFormat":"A number n","outputFormat":"<img src=\"http://pepcoding.com/resources/ojquestionresource/images/pat101.JPG\" alt=\"pat101\">","constraints":"1 &lt;= n &lt;= 100\r\n Also, n is odd.","sampleCode":{"cpp":{"code":"#include <iostream>\r\nusing namespace std;\r\n\r\nint main(int argc, char **argv){\r\n int n;\r\n cin >> n;\r\n\r\n //write your code here\r\n \r\n}"},"java":{"code":"import java.util.*;\r\n\r\npublic class Main{\r\n\r\npublic static void main(String[] args) {\r\n Scanner scn = new Scanner(System.in);\r\n\r\n // write ur code here\r\n\r\n }\r\n}"},"python":{"code":"import math\n\nn = int(input())\n# write ur code here"}},"points":10,"difficulty":"easy","sampleInput":"5","sampleOutput":"\t\t*\t\r\n\t*\t\t*\t\r\n*\t\t\t\t*\t\r\n\t*\t\t*\t\r\n\t\t*\t","questionVideo":"https://www.youtube.com/embed/X90L33S2xk0","hints":[],"associated":[{"id":"15a7dde1-37b8-4031-9cb2-0272123d128b","name":"What will be initial value for inner space? (Pattern 10)","slug":"what-will-be-initial-value-for-inner-space-pattern-10","type":4},{"id":"782b5dc1-0fa6-4fcf-a2dc-1e24e98e9412","name":"What is the order of printing the desired pattern 10?","slug":"what-is-the-order-of-printing-the-desired-pattern-10","type":4},{"id":"93477623-757f-4008-86f9-60d79daf206a","name":"What will be the initial value for outer spaces (pattern 10)?","slug":"what-will-be-the-initial-value-for-outer-spaces-pattern-10","type":4}],"solutionSeen":false,"tags":[],"meta":{"path":[{"id":0,"name":"home"},{"id":"0c54b191-7b99-4f2c-acb3-e7f2ec748b2a","name":"Data Structures and Algorithms","slug":"data-structures-and-algorithms","type":0},{"id":"ca241a91-e685-4c63-9d83-892cf12c5576","name":"Patterns","slug":"patterns-9997","type":0},{"id":"d61735fd-d194-4ada-bcad-9f7cbae0c6cf","name":"Pattern 10","slug":"pattern-10","type":1}],"next":{"id":"800a8209-4537-4dfa-90e5-7cdaa2107fa2","name":"Pattern 10","type":3,"slug":"pattern-10"},"prev":{"id":"056d8563-af67-4b12-b86d-8d871b9921d2","name":"Pattern 9","type":3,"slug":"pattern-9"}}}
plane

Editor


Loading...

Pattern 10

easy

1. You are given a number n. 2. You've to create a pattern of * and separated by tab as shown in output format.

Constraints

1 <= n <= 100 Also, n is odd.

Format

Input

A number n

Output

pat101

Example

Sample Input

5

Sample Output

* * * * * * * *

Question Video

Discussions

Show Discussion

Related Resources

related resources

Turning Off Zen Mode