๐—–๐—ฆ ๐—”๐—น๐—ด๐—ผ ๐Ÿ’ป ๐ŸŒ ใ€Ž๐—–๐—ผ๐—บ๐—ฝ๐—ฒ๐˜๐—ถ๐˜๐—ถ๐˜ƒ๐—ฒ ๐—ฃ๐—ฟ๐—ผ๐—ด๐—ฟ๐—ฎ๐—บ๐—บ๐—ถ๐—ป๐—ดใ€
9.52K subscribers
5.56K photos
3 videos
95 files
9.7K links
๐ŸšฉMain Group - @SuperExams
๐Ÿ“Job Updates - @FresherEarth

๐Ÿ”ฐAuthentic Coding Solutions(with Outputs)
โš ๏ธDaily Job Updates
โš ๏ธHackathon Updates & Solutions

Buy ads: https://telega.io/c/cs_algo
Download Telegram
Attention aspiring Data scientist/Data Engineer

Batch : 2021/2022/2023/2024

Celebal Technologies (Microsoft gold AI partner ) is hiring Data Scientist and Data Engineer.

Mode of Hiring: Hire, Train and Deploy.

You would be given rigorous training by Authorised Hiring Partner, if shortlisted.

Apply Now: https://lnkd.in/diTKXdW5
def maxProfit(costPerCut, salePrice, lengths):
    max_profit = 0

    for sale_length in range(1, max(lengths) + 1):
        sale_price_per_rod = salePrice * sale_length
        profit = 0

        for rod_length in lengths:
            uniform_rods = rod_length // sale_length

            if uniform_rods > 0:
                extra_cut = 1 if rod_length % sale_length > 0 else 0
                total_cuts = uniform_rods - 1 + extra_cut

                costs = total_cuts * costPerCut
                revenues = uniform_rods * sale_price_per_rod

                if revenues > costs:
                    profit += revenues - costs

        if profit > max_profit:
            max_profit = profit

    return max_profit

Cutting Metal Surplus โœ