Ayu-hack / Hacktoberfest-Contributions

This repository helps beginners contribute to open source and participate in Hacktoberfest. We welcome all pull requests (Python & Java), prioritize genuine contributions, and promote good first issues! #hacktoberfest2022 #hacktoberfest2023 #hacktoberfest2024
20 stars 51 forks source link

Create Container-with-most-water #36

Closed imharshtiwari closed 1 year ago

imharshtiwari commented 1 year ago

Find two lines, which together with x-axis forms a container, such that the container contains the most water. The program should return an integer which corresponds to the maximum area of water that can be contained (maximum area instead of maximum volume sounds weird but this is the 2D plane we are working with for simplicity).