Git Product home page Git Product logo

mrarvind90 / python-projects Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 31 KB

Python projects made for the freeCodeCamp Scientific Computing with Python Certification.

Home Page: https://www.freecodecamp.org/learn/scientific-computing-with-python#python-for-everybody

License: Creative Commons Zero v1.0 Universal

Python 100.00%
freecodecamp-certification freecodecamp-python python3 scientific-computing-with-python

python-projects's Introduction

Scientific Computing with Python

About the Projects

This repository contains my solutions to the projects in "Scientific Computing with Python" course from freeCodeCamp.

Project list:

Arithmetic Formatter

A Python program that provides a function for formatting a list of arithmetic problems vertically and side-by-side. Optionally, it can display the answers alongside the problems.

Example

Function Call:

arithmetic_arranger(["32 + 698", "3801 - 2", "45 + 43", "123 + 49"])

Output:

   32      3801      45      123
+ 698    -    2    + 43    +  49
-----    ------    ----    -----

Function Call:

arithmetic_arranger(["32 + 8", "1 - 3801", "9999 + 9999", "523 - 49"], True)

Output:

  32         1      9999      523
+  8    - 3801    + 9999    -  49
----    ------    ------    -----
  40     -3800     19998      474

See all the requirements at FreeCodeCamp

You can try my code at Replit

Time Calculator

A Python program to add time to a 12-hour clock format, with optional day of the week support.

Example

Function Call:

add_time("3:00 PM", "3:10")
# Returns: 6:10 PM

add_time("11:30 AM", "2:32", "Monday")
# Returns: 2:02 PM, Monday

add_time("11:43 AM", "00:20")
# Returns: 12:03 PM

add_time("10:10 PM", "3:30")
# Returns: 1:40 AM (next day)

add_time("11:43 PM", "24:20", "tueSday")
# Returns: 12:03 AM, Thursday (2 days later)

add_time("6:30 PM", "205:12")
# Returns: 7:42 AM (9 days later)

See all the requirements at FreeCodeCamp

You can try my code at Replit

Budget App

A Python program to initialise a budget category object which allows depositing, withdrawing, as well as transferring funds to another budget category object.

Additionally, it can also return a formatted string representation of the category ledger as well as creating visual charts that depict the percentage of spending in each category.

Example

Here is an example of the output when printing out the Category object:

*************Food*************
initial deposit        1000.00
groceries               -10.15
restaurant and more foo -15.89
Transfer to Clothing    -50.00
Total: 923.96

Here is an example of the output when printing out Percentage spent by category chart:

Percentage spent by category
100|          
 90|          
 80|          
 70|          
 60| o        
 50| o        
 40| o        
 30| o        
 20| o  o     
 10| o  o  o  
  0| o  o  o  
    ----------
     F  C  A  
     o  l  u  
     o  o  t  
     d  t  o  
        h     
        i     
        n     
        g 

See all the requirements at FreeCodeCamp

You can try my code at Replit

Polygon Area Calculator

A Python project with a Rectangle class and a Square class, showcasing object-oriented programming. The Rectangle class handles width, height, area, perimeter, diagonal, picture representation, and fitting calculations. The Square class, a subclass of Rectangle, adds single-side handling and method access while maintaining string representation integrity.

Example

Function Call:

rect = shape_calculator.Rectangle(10, 5)
print(rect.get_area()) # Returns: 50

rect.set_height(3)
print(rect.get_perimeter()) # Returns: 26
print(rect) # Returns: Rectangle(width=10, height=3)

"""
Returns: 

**********
**********
**********

"""
print(rect.get_picture())


sq = shape_calculator.Square(9)
print(sq.get_area()) # Returns: 81

sq.set_side(4)
print(sq.get_diagonal()) # Returns: 5.656854249492381
print(sq) # Returns: Square(side=4)

"""
Returns: 

****
****
****
****

"""
print(sq.get_picture()) # Returns:

rect.set_height(8)
rect.set_width(16)
print(rect.get_amount_inside(sq))

See all the requirements at FreeCodeCamp

You can try my code at Replit

Probability Calculator

A Python program to calculate the probability of drawing M number of matching colors over N iteration

See all the requirements at FreeCodeCamp

You can try my code at Replit

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.