Successful Pairs of Spells and Potions: Leetcode 75 in Tamil (தமிழ்)

  Рет қаралды 53

Indic Coder

Indic Coder

Күн бұрын

Пікірлер: 3
@indiccoder
@indiccoder 12 күн бұрын
Java Solution: class Solution { public int[] successfulPairs(int[] spells, int[] potions, long success) { Arrays.sort(potions); // Sort the potions array for binary search int n = potions.length; // Total number of potions int[] res = new int[spells.length]; // Result array to store the count of successful pairs for (int i = 0; i < spells.length; i++) { int spell = spells[i]; int l = 0, u = n - 1; // Initialize binary search boundaries while (l
@indiccoder
@indiccoder 12 күн бұрын
CPP Solution: class Solution { public: vector successfulPairs(vector& spells, vector& potions, long long success) { sort(potions.begin(), potions.end()); // Sort the potions array for binary search int n = potions.size(); // Total number of potions vector res; // Result vector to store the count of successful pairs for (int spell : spells) { int l = 0, u = n - 1; // Initialize binary search boundaries while (l
@indiccoder
@indiccoder 12 күн бұрын
Python Solution: class Solution: def successfulPairs(self, spells: List[int], potions: List[int], success: int) -> List[int]: potions.sort() # Sort the potions array for binary search n = len(potions) # Total number of potions res = [] # Result array to store the number of successful pairs for each spell for spell in spells: l, u = 0, n-1 # Initialize binary search boundaries while l
Keys and Rooms:  Leetcode 75 in Tamil (தமிழ்)
9:12
Indic Coder
Рет қаралды 139
Sliding Window Technique - Algorithmic Mental Models
36:45
Ryan Schachte
Рет қаралды 370 М.
one year of studying (it was a mistake)
12:51
Jeffrey Codes
Рет қаралды 145 М.
7 Outside The Box Puzzles
12:16
MindYourDecisions
Рет қаралды 208 М.
We fixed an inconsistency in Kotlin (non-local break & continue)
10:31
Kotlin by JetBrains
Рет қаралды 4,8 М.
Pongal Paavangal | Parithabangal
13:36
Parithabangal
Рет қаралды 150 М.
Transformers (how LLMs work) explained visually | DL5
27:14
3Blue1Brown
Рет қаралды 4,3 МЛН
как тебе будут продавать в 2025
16:22
Тихон Смирнов
Рет қаралды 348 М.
Полная дорожная карта C# разработчика на платформе .NET
42:40
Александр Алексеев | Папочка Дотнета
Рет қаралды 2,8 М.