Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

Rectangle with python

# Python Program to Print Hollow Rectangle Star Pattern

rows = int(input("Please Enter the Total Number of Rows  : "))
columns = int(input("Please Enter the Total Number of Columns  : "))

print("Hollow Rectangle Star Pattern") 
i = 0
while(i < rows):
    j = 0
    while(j < columns):
        if(i == 0 or i == rows - 1 or j == 0 or j == columns - 1):
            print('*', end = '  ')
        else:
            print(' ', end = '  ')
        j = j + 1
    i = i + 1
    print()
Comment

python how to draw a rectangle

import turtle
for i in range(2):
  turtle.forward(20)
  turtle.right(90)
  turtle.forward(10)
Comment

python how to draw a rectangle

import turtle
for i in range(2):
  turtle.forward(20)
  turtle.right(90)
  turtle.forward(10)
Comment

PREVIOUS NEXT
Code Example
Python :: Python - Comment jouer le fichier Mp3 
Python :: XML to MS SQL 
Python :: oop - Apa metaclasses di Python 
Python :: geomertry 
Python :: add hours to date time in python 
Python :: extract area code from phone number python 
Python :: softmax for nparray 
Python :: Check for strings as positive/negative - integer/float 
Python :: Get Project Parameter Dynamo Revit 
Python :: countvectorizer minimum frequency 
Python :: group by weekhour 
Python :: change set item python 
Python :: pairwise swap in data structure in python 
Python :: pandas : stratification (mean) 
Python :: violin plot seaborn 
Python :: sum 1-50 
Python :: Herons rule python 
Python :: multi hot encode pandas column 
Python :: pyqt5 open tab 
Python :: pandas convert text duration to minutes 
Python :: pasar tupla a funcion python 
Python :: seeparate string without split function python 
Python :: mp.solutions.findhands not in python 3.8 
Python :: fetch api flask url redirect 
Python :: nlargest of each group 
Python :: Can the string find method be used to search a list? 
Python :: check entries smaller 0 after groupby 
Python :: how to convert 2 dimensional in 1 dimensional array 
Python :: Creating sub elements in xml in python with ElementTree 
Python :: python range for loop 
ADD CONTENT
Topic
Content
Source link
Name
4+1 =