Skip to content
TechDecode Tutorials

TechDecode Tutorials

Short and Simple Tech Tutorials

  • C++
    • C++ Programs
    • C++ Tutorials
    • C++ Course
    • C Programs
    • C Tutorials
  • Java
    • Java Notes
    • Programs
    • Tutorials
    • Java Courses
  • Python
    • Python Notes
    • Programs
    • Tutorials
    • Python Course
  • c#
    • C# Courses
  • Web Development
    • HTML
    • CSS
    • Javascript
      • Javascript Program
      • JavaScript Course
    • PHP
  • Data Science
    • R Programming
    • Data Science Courses
  • Application
  • Download
  • Tech
    • Cyber Security
    • Cyber Security Courses
Python Notes Python Programs 

Star Pyramid Pattern using One Line Python Code

July 27, 2022July 28, 2022 Yogendra Singh one liner star pattern python, star pattern one line python

In this tutorial, we are going to show How to print a star pattern using one line of python code. We have added the video tutorial and the source code of the program.

Video Tutorial: Star Pyramid Pattern using One Line Python Code

Source Code

# One Liner Star Pattern Python Code

print('\n'.join('* ' * i for i in range(1,6))) 

Also Read: Python program to create BMI calculator

Output

Also Read: How to run python in visual studio code

Join Now: Learn Python Programming Masterclass

  • ← Reverse a List using One Line Python Code
  • Print Even Numbers using One Line Python Code →

You May Also Like

Print Prime Numbers Between Two Integers Python Program

Print Prime Numbers Between Two Integers in python

September 18, 2021September 16, 2021 Ethix

Draw Among Us Character Using Python Turtle

April 13, 2022April 13, 2022 Nihal Prasad

Implement Linear Search using Python

September 20, 2021September 21, 2021 Ethix

Python

  • Python - Introduction
  • Python - Syntax
  • Python - Comments
  • Python - Variables
  • Python - Data Types
  • Python - Numbers
  • Python - Type Casting
  • Python - Operators
  • Python - Booleans
  • Python - Strings
  • Python - Lists
  • Python - Tuples
  • Python - Sets
  • Python - Dictionary
  • Python - If Else
  • Python - While Loop
  • Python - For Loop
  • Python - Continue Statement
  • Python - Break Statement
  • Python - Functions
  • Python - Lamda Function
  • Python - Scope of Variables
  • Python - Modules
  • Python - Iterators

About Us

logo
Our mission is to deliver technical tutorials with clear, crisp, and to-the-point content on a wide range of subjects without any preconditions and impediments.

Company

  • About Us
  • Internship
  • Contact Us
  • Privacy Policy
  • Copyright Policy

Learn

  • C++
  • Java
  • Python
  • R Programming
  • Web Development

Powered By

Accounting Software Powered by Refrens

Copyright © 2025 TechDecode Tutorials. All rights reserved.
Theme: ColorMag by ThemeGrill. Powered by WordPress.