We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Loading...
  • Practice
  • Compete
  • Jobs
  • Leaderboard
  • Hiring developers?
  1. Practice
  2. Algorithms
  3. Warmup
  4. Staircase
  5. Discussions

Staircase

  • Problem
  • Submissions
  • Leaderboard
  • Discussions
  • Editorial

    You are viewing a single comment's thread. Return to all comments →

  • michelbetancour1 2 years ago+ 1 comment

    one liner

    (lambda num: [print(('#'*x).rjust(num)) for x in range(num+1)])(int(input().strip()))
    
    0|
    ParentPermalink
    • mahamadbilal696 1 year ago+ 0 comments

      i have got the error as follows...

      (lambda num: [print(('#'*x).rjust(num)) for x in range(num+1)])(int(input().strip())) ^ SyntaxError: invalid syntax

      can you please help me why it so.....

      0|
      ParentPermalink
  • Contest Calendar
  • Blog
  • Scoring
  • Environment
  • FAQ
  • About Us
  • Support
  • Careers
  • Terms Of Service
  • Privacy Policy
  • Request a Feature