Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Cricbuzz.com is hiring Full Stack Developer
For 2021, 2022, 2023 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3978712961
For 2021, 2022, 2023 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3978712961
Linkedin
Cricbuzz.com hiring Full Stack Engineer in Bengaluru, Karnataka, India | LinkedIn
Posted 11:57:51 AM. We are seeking a talented Full Stack Developer with 1-2 years of experience in Node.js to join ourโฆSee this and similar jobs on LinkedIn.
int minimumCost(int input1, int input2, int input3, int **input4) {
int N = input1;
int M = input2;
int K = input3;
unordered_map<int, int> degree;
for (int i = 0; i < M; ++i) {
int u = input4[i][0];
int v = input4[i][1];
degree[u]++;
degree[v]++;
}
int count = 0;
for (const auto& pair : degree) {
if (pair.second > 1) {
count++;
}
}
return count * K;
}
Desmus and the Check Centersโ
int N = input1;
int M = input2;
int K = input3;
unordered_map<int, int> degree;
for (int i = 0; i < M; ++i) {
int u = input4[i][0];
int v = input4[i][1];
degree[u]++;
degree[v]++;
}
int count = 0;
for (const auto& pair : degree) {
if (pair.second > 1) {
count++;
}
}
return count * K;
}
Desmus and the Check Centersโ
SELECT
i.invoice_number,
c.customer_name,
COUNT(co.id) AS number_of_contacts
FROM
customer c
JOIN
invoice i ON c.id = i.customer_id
LEFT JOIN
contact co ON c.id = co.customer_id AND co.contact_start_time < i.invoice_date
LEFT JOIN
user_account ua ON co.user_account_id = ua.id
WHERE
i.user_account_id NOT IN (
SELECT DISTINCT user_account_id
FROM contact
WHERE customer_id = c.id AND contact_start_time < i.invoice_date
)
GROUP BY
i.id, c.id
ORDER BY
i.invoice_number ASC
๐1
#include <iostream>
#include <vector>
#include <queue>
using namespace std;
int minimumPower(vector<int>& cells) {
priority_queue<int, vector<int>, greater<int>> minHeap(cells.begin(), cells.end());
int totalPower = 0;
while (minHeap.size() > 1) {
int first = minHeap.top();
minHeap.pop();
int second = minHeap.top();
minHeap.pop();
int power = first + second;
totalPower += power;
minHeap.push(power);
}
return totalPower;
}
MINPOWERโ
SELECT
CASE
WHEN t.table_name = 'offline_sites' THEN 'Offline'
WHEN t.table_name = 'online_sites' THEN 'Online'
WHEN t.table_name = 'suspended_sites' THEN 'Suspended'
END AS status,
COUNT(*) AS total_sites
FROM (
SELECT 'offline_sites' AS table_name, customer_id, domain_name, is_active FROM offline_sites
UNION ALL
SELECT 'online_sites' AS table_name, customer_id, domain_name, is_active FROM online_sites
UNION ALL
SELECT 'suspended_sites' AS table_name, customer_id, domain_name, is_active FROM suspended_sites
) t
JOIN customers c ON t.customer_id = c.id
WHERE c.is_active = 1 AND t.is_active = 1
GROUP BY t.table_name
ORDER BY
CASE
WHEN t.table_name = 'offline_sites' THEN 1
WHEN t.table_name = 'online_sites' THEN 2
WHEN t.table_name = 'suspended_sites' THEN 3
END;
Meesho online, offline, suspendedโ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
SELECT
c.name,
ROUND(SUM(CASE WHEN EXTRACT(QUARTER FROM t.dt) = 1 THEN t.amount ELSE 0 END), 2) AS q1_amount,
ROUND(SUM(CASE WHEN EXTRACT(QUARTER FROM t.dt) = 2 THEN t.amount ELSE 0 END), 2) AS q2_amount,
ROUND(SUM(CASE WHEN EXTRACT(QUARTER FROM t.dt) = 3 THEN t.amount ELSE 0 END), 2) AS q3_amount,
ROUND(SUM(CASE WHEN EXTRACT(QUARTER FROM t.dt) = 4 THEN t.amount ELSE 0 END), 2) AS q4_amount,
COUNT(t.coin_id) AS total_transactions,
ROUND(SUM(t.amount), 2) AS total_amount
FROM
coins c
LEFT JOIN
transactions t ON c.id = t.coin_id AND EXTRACT(YEAR FROM t.dt) = 2023
GROUP BY
c.name
ORDER BY
c.name ASC;
Meesho cryptoโ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
OKX Graduate Hire 2024/25 - Software Engineer
Singapore
Batch: 2024
https://job-boards.greenhouse.io/okx/jobs/6075806003?gh_src=8ad01c4c3us
Singapore
Batch: 2024
https://job-boards.greenhouse.io/okx/jobs/6075806003?gh_src=8ad01c4c3us
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Cognizant Technology Solutions is hiring for Programmer Trainee
Three year degree grads allowed
Apply Here : https://bit.ly/ITPT2024
Three year degree grads allowed
Apply Here : https://bit.ly/ITPT2024
๐1
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Myntra hiring for 6 Months Internship for PwD Candidates.
Both tech and non-tech roles
https://docs.google.com/forms/d/e/1FAIpQLScrF_4P_aP7qKR8AJinZZ0wFY8t8G-6wVqSNq3O-2xgAvMLkg/viewform
Both tech and non-tech roles
https://docs.google.com/forms/d/e/1FAIpQLScrF_4P_aP7qKR8AJinZZ0wFY8t8G-6wVqSNq3O-2xgAvMLkg/viewform
#include <bits/stdc++.h>
using namespace std;
#define ll long long
ll solve(ll n)
{
vector<ll>bin(32);
ll i=0;
while(n)
{
bin[i]=n%2;
n=n/2;
i++;
}
string s;
for(ll j=i-1;j>=0;j--) s.push_back((char)(bin[j]+'0'));
//cout<<s<<endl;
n=s.length();
ll ans=0,f=1;
for(ll i=0;i<n;i++)
{
ll dig=s[i]-'0';
ll p=dig>0?pow(2,n-(i+1)):0;
ll st=dig*(2*p-1);
ans+=st*f;
if(dig==0) f=1;
else f=-1;
}
return ans;
}
signed main()
{
ll n; cin>>n;
cout<<solve(n);
}
Binary Manipulation โ
using namespace std;
#define ll long long
ll solve(ll n)
{
vector<ll>bin(32);
ll i=0;
while(n)
{
bin[i]=n%2;
n=n/2;
i++;
}
string s;
for(ll j=i-1;j>=0;j--) s.push_back((char)(bin[j]+'0'));
//cout<<s<<endl;
n=s.length();
ll ans=0,f=1;
for(ll i=0;i<n;i++)
{
ll dig=s[i]-'0';
ll p=dig>0?pow(2,n-(i+1)):0;
ll st=dig*(2*p-1);
ans+=st*f;
if(dig==0) f=1;
else f=-1;
}
return ans;
}
signed main()
{
ll n; cin>>n;
cout<<solve(n);
}
Binary Manipulation โ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
public static int getMinCost(int[] heights, int[] cost) {
int n = heights.length;
int[][] dp = new int[n][3];
for (int i = 0; i < n; i++) {
if (i == 0) {
dp[i][0] = 0;
dp[i][1] = cost[i];
dp[i][2] = 2 * cost[i];
} else {
dp[i][0] = Math.min((heights[i - 1] != heights[i] ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] ? dp[i - 1][2] : Integer.MAX_VALUE)));
dp[i][1] = Math.min((heights[i - 1] != heights[i] + 1 ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] + 1 ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] + 1 ? dp[i - 1][2] : Integer.MAX_VALUE))) + cost[i];
dp[i][2] = Math.min((heights[i - 1] != heights[i] + 2 ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] + 2 ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] + 2 ? dp[i - 1][2] : Integer.MAX_VALUE))) + 2 * cost[i];
}
}
return Math.min(dp[n - 1][0], Math.min(dp[n - 1][1], dp[n - 1][2]));
}
Unequal Block Structureโ
int n = heights.length;
int[][] dp = new int[n][3];
for (int i = 0; i < n; i++) {
if (i == 0) {
dp[i][0] = 0;
dp[i][1] = cost[i];
dp[i][2] = 2 * cost[i];
} else {
dp[i][0] = Math.min((heights[i - 1] != heights[i] ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] ? dp[i - 1][2] : Integer.MAX_VALUE)));
dp[i][1] = Math.min((heights[i - 1] != heights[i] + 1 ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] + 1 ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] + 1 ? dp[i - 1][2] : Integer.MAX_VALUE))) + cost[i];
dp[i][2] = Math.min((heights[i - 1] != heights[i] + 2 ? dp[i - 1][0] : Integer.MAX_VALUE),
Math.min((heights[i - 1] + 1 != heights[i] + 2 ? dp[i - 1][1] : Integer.MAX_VALUE),
(heights[i - 1] + 2 != heights[i] + 2 ? dp[i - 1][2] : Integer.MAX_VALUE))) + 2 * cost[i];
}
}
return Math.min(dp[n - 1][0], Math.min(dp[n - 1][1], dp[n - 1][2]));
}
Unequal Block Structureโ