๐—–๐—ฆ ๐—”๐—น๐—ด๐—ผ ๐Ÿ’ป ๐ŸŒ ใ€Ž๐—–๐—ผ๐—บ๐—ฝ๐—ฒ๐˜๐—ถ๐˜๐—ถ๐˜ƒ๐—ฒ ๐—ฃ๐—ฟ๐—ผ๐—ด๐—ฟ๐—ฎ๐—บ๐—บ๐—ถ๐—ป๐—ดใ€
9.63K subscribers
5.61K photos
3 videos
95 files
10.6K 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;

vector<int> solve(int N, int M, vector<int> time) {
    vector<int> ans(M, 0);
    vector<vector<int>> v(N);
   
    for(int i = 0; i < M; ++i) {
        v[i % N].push_back(i);
    }

    int departure = 0;

    for(int i = 0; i < N; ++i) {
        if(!v[i].empty()) {
            ans[v[i][0]] = time[v[i][0]] + 1;
            departure = ans[v[i][0]];
        }
        for(int j = 1; j < v[i].size(); ++j) {
            int idx = v[i][j];
            int val1 = time[idx];
            if(departure > val1) {
                ans[idx] = departure + 1;
                departure++;
            } else {
                departure = val1 + 1;
                ans[idx] = departure;
            }
        }
    }

    return ans;
}

Shopping and Billing โœ…
Hiring for US Banking domain for freshers 2023 , 24 yr passed out

Work location - Accenture , Chennai

wfo option . US shift

knowledge needed in accounts , finance , basic banking skills

Good comm skills needed

Share ur resume to HR

Adarsh.elango@accenture.com
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int T = scanner.nextInt();

        for (int t = 0; t < T; t++) {
            int S = scanner.nextInt();
            int N = scanner.nextInt();
            int M = scanner.nextInt();

            int result = minDaysToBuyFood(S, N, M);
            System.out.println(result);
        }

        scanner.close();
    }

    private static int minDaysToBuyFood(int S, int N, int M) {
        int low = 0;
        int high = S;

        while (low <= high) {
            int mid = (low + high) / 2;

            if (canSurvive(S, N, M, mid)) {
                high = mid - 1;
            } else {
                low = mid + 1;
            }
        }

        if (low > S) {
            return -1;
        }

        return low;
    }

    private static boolean canSurvive(int S, int N, int M, int days) {
        int food = (N - N/7) * days;
        int foodRequired = M * S;

        return food >= foodRequired;
    }
}. 

Island survival โœ…
#include <iostream>
#include <vector>
#include <queue>

using namespace std;

bool canFinish(int n, vector<vector<int>> &edges) {
    int cnt = 0;
    vector<int> adjList[n];
    int m = edges.size();
    vector<int> indegree(n, 0);

    for (int i = 0; i < m; i++) {
        adjList[edges[i][1]].push_back(edges[i][0]);
        indegree[edges[i][0]]++;
    }

    queue<int> q;

    for (int i = 0; i < n; i++)
        if (indegree[i] == 0)
            q.push(i);

    while (!q.empty()) {
        int node = q.front();
        cnt++;
        q.pop();
        int m = adjList[node].size();
        for (int i = 0; i < m; i++) {
            int adjNode = adjList[node][i];
            indegree[adjNode]--;
            if (indegree[adjNode] == 0)
                q.push(adjNode);
        }
    }
    return (cnt == n);
}

int main() {
    int n, m;
    cin >> n >> m;
    vector<vector<int>> edges(m, vector<int>(2));

    for (int i = 0; i < m; i++)
        cin >> edges[i][0] >> edges[i][1];

    if (canFinish(n, edges))
        cout << "true";
    else
        cout << "false";

    return 0;
}
    
/// Course Prerequisites โœ…
import java.util.Scanner;
import java.util.TreeSet;

public class Main {
    public static int countValidSubarrays(int[] A, int B, int C) {
        int n = A.length;
        int count = 0;
        long[] prefixSum = new long[n + 1];
        prefixSum[0] = 0;
        for (int i = 0; i < n; i++) {
            prefixSum[i + 1] = prefixSum[i] + A[i];
        }
        TreeSet<Long> set = new TreeSet<>();
        set.add(0L);

        for (int i = 1; i <= n; i++) {
            long lowerBound = prefixSum[i] - C;
            long upperBound = prefixSum[i] - B;

            count += set.subSet(lowerBound, true, upperBound, true).size();

            set.add(prefixSum[i]);
        }

        return count;
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();
        int B = sc.nextInt();
        int C = sc.nextInt();
        int[] A = new int[N];
        for (int i = 0; i < N; i++) {
            A[i] = sc.nextInt();
        }
        int result = countValidSubarrays(A, B, C);
        System.out.println(result);
       
        sc.close();
    }
}.

Range Bokking olx โœ…
Accenture Business Solutions Pvt Ltd - Walk in drive

Drive Date - 23rd May 2024

Drive Time - 10.30am to 2.00pm

Requirement - B.com degree

Experience - Freshers and maximum 2 years experience in Accounts and Financial Services

Work Location - Chennai

Drive Location - CDC5, Accenture, Sholinganallur

Note - Candidates will not be considered without proper CID

Only candidates from Chennai are preferred

Documents to bring - PAN card, Aadhar card, all career documents, 2 Photos, 3 copies of Resumes

If you have already applied in the Accenture Portal, you can use the CID number which you got after applying on the portal and attend the interview.
string intToBinary(int n) {
    string binary = "";
    while (n > 0) {
        binary = to_string(n % 2) + binary;
        n /= 2;
    }
    return binary;
}

string maximumBinary(int numberofBits, int maximumOperationsAllowed, vector<string>& arr) {
    vector<int> int_arr;
    for (const string& s : arr) {
        int_arr.push_back(stoi(s, 0, 2));
    }

    vector<int> calculated_values;
    for (int x : int_arr) {
        calculated_values.push_back(((1 << numberofBits) - 1) ^ x);
    }

    vector<int> sorted_arr(int_arr.begin(), int_arr.end());
    sort(sorted_arr.begin(), sorted_arr.end(), [&](int a, int b) {
        return calculated_values[a] > calculated_values[b];
    });

    int total = 0;
    for (int i = 0; i < sorted_arr.size(); ++i) {
        int x = sorted_arr[i];
        if (i < min(maximumOperationsAllowed, (int)arr.size())) {
            total += max(((1 << numberofBits) - 1) ^ x, x);
        } else {
            total += x;
        }
    }

    return intToBinary(total);
}

Max Binary โœ