Python Coding Challenges for Pleasure Month Apply


Finishing code challenges, bite-sized issues that may be solved with code, is a superb solution to sharpen particular coding abilities and ideas — to not point out, code challenges are enjoyable. In honor of Pleasure Month this June, we’re providing you with a listing of code challenges to attempt that each one relate to uplifting the LGBTQ+ neighborhood and its allies. 

These coding challenges provides you with mixture of Python ideas to follow, like lists, strings, conditionals, and constructions. Relying in your expertise degree, a few of these challenges solely take a couple of minutes to finish, whereas the harder ones may take a pair days. Chances are you’ll need to revisit a Python course to evaluation (we’ve advisable the related Python programs to attempt alongside the way in which). 

As you’ll see, these are open-ended challenges and we’re not offering options. That’s as a result of we need to provide you with an opportunity to follow key coding abilities and apply your coding data to real-world eventualities. We hope you are feeling impressed by the entire methods you may use code to provide again to the communities and causes that you just care about. Joyful Pleasure and glad coding!

1. Affirmation Engine

Write a Python program that takes a person’s pronouns as enter and returns a message that features their pronouns and an announcement of respect for his or her gender id. An instance of a message may very well be: “Thanks for sharing that your pronouns are {pronouns}. We wholeheartedly respect and affirm your gender id, and recognize your assist in constructing an inclusive surroundings the place everybody feels valued and accepted.

2. STEM Icons Sorter

Create a Python program that takes a listing of LGBTQ+ historic figures as enter and returns a brand new checklist with the phrases sorted alphabetically. Wish to brush up in your queer historical past? Find out about trailblazing LGBTQ+ figures in our free course LGBTQ+ STEM Icons.

3. ASCII Artist

Within the beginner-friendly course Study Python 3, you’ll get launched to ASCII artwork, a kind of text-based visible artwork that makes use of particular person characters to create footage and diagrams. Write a Python program that prints “PRIDE” in ASCII block letters. You may reference the entire ASCII alphabet utilizing this chart.

4. Pleasure March Countdown

Write a Python program that calculates the variety of days, hours, and minutes remaining till the annual NYC Pleasure March, which begins on June 25 at 12 pm EDT. This system ought to show the countdown in a user-friendly format. For a refresher on working with date time knowledge in Python, learn this text

5. Acronym Explainer

Create a change loop that prints the phrases represented within the acronym LGBTQ+, that are: lesbian, homosexual, bisexual, transgender, queer, and non-straight/non-cisgender identities.

6. Rainbow Message Generator

You’re given a message, “Code with pleasure!” that must be remodeled right into a rainbow-themed string the place every letter is a special colour within the LGBTQ+ Pleasure flag. Your process is to put in writing a Python operate that takes the message as enter and returns the rainbow model of the message. Sizzling tip: You should utilize ANSI escape codes to use colour to textual content in Python.

7. Pronoun Apply Chatbot

Develop a easy chatbot that helps you follow utilizing somebody’s pronouns in several contexts. This code problem is essentially the most superior one within the bunch, however don’t be intimidated. Within the talent path Construct Chatbots with Python, you’ll discover ways to code rule-based, retrieval-based, and generative chatbots. One of the best half is you don’t want coding expertise to get began — we’ll educate you to code with Python from scratch. 

8. Analysis LGBTQ+ Illustration

Construct a program that reads a dataset (you may use this pre-made dataset) and analyzes the illustration of LGBTQ+ characters in cartoons. This system ought to calculate and show statistics, like every tendencies or modifications in illustration through the years. For those who’re new to knowledge science, take a look at the course Getting Began with Python for Information Science. You’ll get to work hands-on with actual datasets within the course, and be taught to make use of Jupyter Pocket book, an industry-standard knowledge analytics platform.

9. Pronoun Reminder

    Create a easy Python program that takes a person’s title and pronouns as enter after which reminds the person to make use of these pronouns in a sentence. For instance, if the person inputs “Alex” and “they/them,” this system ought to output a message like, “Alex makes use of they/them pronouns!” You’ll discover ways to assign variables with person enter in Study Python 3.

    10. Inclusive Language Checker

      Develop a Python program that checks a given textual content for the usage of inclusive language. This system ought to establish phrases or phrases that could be thought of unique or insensitive and counsel extra inclusive alternate options. For instance, it might counsel changing “guys” with “people” or “y’all.” This train will aid you follow string manipulation and dictionary knowledge constructions. To be taught extra about how computer systems work with human language, take a look at the trail Apply Pure Language Processing with Python.

      Need much more Python concepts? Attempt these Python code challenges for rookies, or work your means as much as superior coding challenges. You may also evaluation these code challenges, that are all based mostly on real-world technical interviews. For those who really feel such as you’ve obtained a deal with on code challenges, be sure you take a look at our library of Python initiatives you could full for follow or your skilled portfolio.

      This weblog was initially printed in June 2023 and has been up to date to incorporate further Python challenges.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *