๐—–๐—ฆ ๐—”๐—น๐—ด๐—ผ ๐Ÿ’ป ๐ŸŒ ใ€Ž๐—–๐—ผ๐—บ๐—ฝ๐—ฒ๐˜๐—ถ๐˜๐—ถ๐˜ƒ๐—ฒ ๐—ฃ๐—ฟ๐—ผ๐—ด๐—ฟ๐—ฎ๐—บ๐—บ๐—ถ๐—ป๐—ดใ€
9.65K subscribers
5.62K photos
3 videos
95 files
10.9K 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
#include <bits/stdc++.h>
using namespace std;
long long comb(int n, int r) {
    if (r > n) return 0;
    if (r == 0 || r == n) return 1;
    long long res = 1;
    for (int i = 0; i < r; i++) {
        res = res * (n - i) / (i + 1);
    }
    return res;
}
long long Balanced(int A, int B, int C) {
    long long s = 0;
    for (int p = 4; p <= min(A, C - 1); p++) {
    int w = C - p;
    if (w >= 1 && w <= B) {
    s += comb(A, p) * comb(B, w);
        }
    }
    return s;
} // Balance Mixture
โœ…
#include <iostream>
#include <string>
#include <cmath>
using namespace std;
int gap(char a, char b) {
    return abs(a - b);
}
string longestKInterspaceSubstring( string &word, int k) {
    string temp = "", maxSubstring = "";
    for (size_t i = 0; i < word.length(); i++) {
    temp += word[i];
    if (i < word.length() - 1 && gap(word[i], word[i + 1]) > k) {
    if (temp.length() > maxSubstring.length()) {
    maxSubstring = temp;
    }
    temp = "";
        }
    }
    if (temp.length() > maxSubstring.length()) {
        maxSubstring = temp;
    }

    return maxSubstring;
}


Longest K intersapace substring โœ…
Paypal