๐—–๐—ฆ ๐—”๐—น๐—ด๐—ผ ๐Ÿ’ป ๐ŸŒ ใ€Ž๐—–๐—ผ๐—บ๐—ฝ๐—ฒ๐˜๐—ถ๐˜๐—ถ๐˜ƒ๐—ฒ ๐—ฃ๐—ฟ๐—ผ๐—ด๐—ฟ๐—ฎ๐—บ๐—บ๐—ถ๐—ป๐—ดใ€
9.62K subscribers
5.59K photos
3 videos
95 files
10.2K 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
*Infosys Recruitment - 2024 Batch*

*Infosys is hiring Specialist Programmers through their off-campus recruitment program!*

Compensation:

โ‚น13 LPA (based on performance)
โ‚น9.5 LPA (based on selection process)

Eligibility:

Courses: BE, BTech, ME, MTech, MCA, MSc (Integrated 5 years), MSc (Mathematics)
Branches: All branches
Academic Criteria:
10th & 12th: 60%
Graduation & Post-graduation: 6 CGPA

Deadline to Apply: Wednesday, 11th September 2024

Apply Here: https://surveys.infosysapps.com/r/a/Infosys_SPhiring_24BATCH_NATCOLLEGES
#include <iostream>
#include <queue>
#include <string>
#include <vector>

using namespace std;

int solve(int K) {
    queue<string> q;
    for (char evenDigit : {'2', '4', '6', '8'}) {
        q.push(string(1, evenDigit));
    }
    int count = 0;
    while (!q.empty()) {
        string currentNum = q.front();
        q.pop();
        count++;
        if (count == K) {
            return stoi(currentNum);
        }
        int length = currentNum.length();
        if (length % 2 == 1) {
            for (char oddDigit : {'1', '3', '5', '7', '9'}) {
                q.push(currentNum + oddDigit);
            }
        } else {
            for (char evenDigit : {'2', '4', '6', '8'}) {
                q.push(currentNum + evenDigit);
            }
        }
    }
    return -1;
}

INTERESTING  NUMBERSโœ…
#include <iostream>
#include <vector>
#include <algorithm>
long long solution(int n, long long c, int d, std::vector<int> arr) {
    sort(arr.begin(), arr.end());
    long long val1 = arr[n-1], days = d;
    if (val1 * days < c) return -1;
    if (val1 >= c) return -1;
    long long ans = 1e16, st = 0, en = 1e16;
    while (st <= en) {
        long long mid = st + (en - st) / 2;
        long long p = mid + 1;
        int el = 0;
        long long cur = 0;
        for (int i = n - 1; i >= 0; i--) {
            el++;
            if (el > p) break;
            cur += (days / p) * (long long)arr[i];
            if (days % p >= el) cur += (long long)arr[i];
        }
                if (cur >= c) {
            ans = mid;
            st = mid + 1;
        } else {
            en = mid - 1;
        }
    }
    return ans;
}
๐Ÿ‘1
import requests
def getArticleTitles(author):
    titles = []
    page = 1
    base_url = f"https://jsonmock.hackerrank.com/api/articles?author={author}&page="
    while True:
        response = requests.get(base_url + str(page))
        data = response.json()
        for article in data['data']:
            if article['title']:
                titles.append(article['title'])
            elif article['story_title']:
                titles.append(article['story_title'])
        if page >= data['total_pages']:
            break
        page += 1
    return titles


Get Author Articles โœ