๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
set<ll> primes(ll n)
{
map<ll,ll>mp;
set<ll>st;
while (n % 2 == 0)
{
mp[2]++;
n = n/2;
}
for (int i = 3; i <= sqrt(n); i = i + 2)
{
while (n % i == 0)
{
mp[i]++;
n = n/i;
}
}
if (n > 2)
mp[n]++;
for(auto it:mp){
if(it.ss%2==1){
st.insert(it.ff);
}
}
return st;
}
ll getNonPerfectPairs(ll n, vl arr,ll k){
map<set<ll>,ll>mp;
ll cnt=0;
for(int i=0;i<n;i++){
set<ll>temp=primes(arr[i]);
mp[temp]++;
}
vl ans;
for(auto it:mp){
ans.pb(it.ss);
}
sort(all(ans));
priority_queue<ll>pq;
for(int i=0;i<ans.size();i++){
pq.push({ans[i]});
}
debug(ans);
while(pq.size()>1){
ll x=pq.top();
pq.pop();
ll y=pq.top();
pq.pop();
cnt++;
if(x-1>0){
pq.push(x-1);
}
if(y-1>0){
pq.push(y-1);
}
}
ll temp=0;
if(pq.size()>0){
temp=pq.top();
}
debug(temp);
ll mini=min(k,temp/2);
cnt+=mini;
cout<<cnt<<endl;
}
Schrodinger โ
{
map<ll,ll>mp;
set<ll>st;
while (n % 2 == 0)
{
mp[2]++;
n = n/2;
}
for (int i = 3; i <= sqrt(n); i = i + 2)
{
while (n % i == 0)
{
mp[i]++;
n = n/i;
}
}
if (n > 2)
mp[n]++;
for(auto it:mp){
if(it.ss%2==1){
st.insert(it.ff);
}
}
return st;
}
ll getNonPerfectPairs(ll n, vl arr,ll k){
map<set<ll>,ll>mp;
ll cnt=0;
for(int i=0;i<n;i++){
set<ll>temp=primes(arr[i]);
mp[temp]++;
}
vl ans;
for(auto it:mp){
ans.pb(it.ss);
}
sort(all(ans));
priority_queue<ll>pq;
for(int i=0;i<ans.size();i++){
pq.push({ans[i]});
}
debug(ans);
while(pq.size()>1){
ll x=pq.top();
pq.pop();
ll y=pq.top();
pq.pop();
cnt++;
if(x-1>0){
pq.push(x-1);
}
if(y-1>0){
pq.push(y-1);
}
}
ll temp=0;
if(pq.size()>0){
temp=pq.top();
}
debug(temp);
ll mini=min(k,temp/2);
cnt+=mini;
cout<<cnt<<endl;
}
Schrodinger โ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
def updatePrefixSum(prefixSum, x1, y1, x2, y2, h):
prefixSum[y1][x1] += h
if x2 + 1 < len(prefixSum[0]):
prefixSum[y1][x2 + 1] -= h
if y2 + 1 < len(prefixSum):
prefixSum[y2 + 1][x1] -= h
if x2 + 1 < len(prefixSum[0]) and y2 + 1 < len(prefixSum):
prefixSum[y2 + 1][x2 + 1] += h
def calculateTotalWater(prefixSum, x1, y1, x2, y2):
total = 0
for i in range(y1, y2 + 1):
for j in range(x1, x2 + 1):
if i > 0:
prefixSum[i][j] += prefixSum[i - 1][j]
if j > 0:
prefixSum[i][j] += prefixSum[i][j - 1]
if i > 0 and j > 0:
prefixSum[i][j] -= prefixSum[i - 1][j - 1]
total += prefixSum[i][j]
return total
def rainInRectangle():
n, m, k, q = map(int, input().split())
prefixSum = [[0] * (n + 1) for _ in range(m + 1)]
for _ in range(k):
x1, y1, x2, y2, h = map(int, input().split())
updatePrefixSum(prefixSum, x1 - 1, y1 - 1, x2 - 1, y2 - 1, h)
results = []
for _ in range(q):
x1, y1, x2, y2 = map(int, input().split())
result = calculateTotalWater(prefixSum, x1 - 1, y1 - 1, x2 - 1, y2 - 1)
results.append(result)
return results
Phonepe โ
#include <iostream>
#include <string>
#include <algorithm>
#include <vector>
using namespace std;
bool cmp(const string& s, const string& t) {
if (s.size() == t.size()) {
return s < t;
}
return s.size() < t.size();
}
void SolvePuzzle(int n, vector<string>& str) {
vector<string> ans;
for (int i = 0; i < n; i++) {
string s = str[i];
int j = 0;
while (j < s.size()) {
string temp;
while (j < s.size() && s[j] >= '0' && s[j] <= '9') {
temp += s[j];
j++;
}
if (!temp.empty()) {
string frzi = "";
string rest = "0";
bool xx = false;
for (int k = 0; k < temp.size(); k++) {
if (temp[k] == '0' && !xx) {
continue;
} else {
frzi += temp[k];
xx = true;
}
}
if (!xx) {
ans.push_back(rest);
} else {
ans.push_back(frzi);
}
}
j++;
}
}
sort(ans.begin(), ans.end(), cmp);
for (const auto& str : ans) {
cout << str << endl;
}
}
int main() {
int n;
cin >> n;
vector<string> str(n);
for (int i = 0; i < n; ++i) {
cin >> str[i];
}
SolvePuzzle(n, str);
return 0;
}
Amelia โ
Tesco
#include <string>
#include <algorithm>
#include <vector>
using namespace std;
bool cmp(const string& s, const string& t) {
if (s.size() == t.size()) {
return s < t;
}
return s.size() < t.size();
}
void SolvePuzzle(int n, vector<string>& str) {
vector<string> ans;
for (int i = 0; i < n; i++) {
string s = str[i];
int j = 0;
while (j < s.size()) {
string temp;
while (j < s.size() && s[j] >= '0' && s[j] <= '9') {
temp += s[j];
j++;
}
if (!temp.empty()) {
string frzi = "";
string rest = "0";
bool xx = false;
for (int k = 0; k < temp.size(); k++) {
if (temp[k] == '0' && !xx) {
continue;
} else {
frzi += temp[k];
xx = true;
}
}
if (!xx) {
ans.push_back(rest);
} else {
ans.push_back(frzi);
}
}
j++;
}
}
sort(ans.begin(), ans.end(), cmp);
for (const auto& str : ans) {
cout << str << endl;
}
}
int main() {
int n;
cin >> n;
vector<string> str(n);
for (int i = 0; i < n; ++i) {
cin >> str[i];
}
SolvePuzzle(n, str);
return 0;
}
Amelia โ
Tesco
def solution(laps):
drivers = {}
eliminated = []
for lap in laps:
slowest = float('-inf')
toRemove = []
for info in lap:
name, time = info.split()
time = int(time)
drivers[name] = min(drivers.get(name, time), time)
if drivers[name] > slowest:
slowest = drivers[name]
toRemove = [name]
elif drivers[name] == slowest:
toRemove.append(name)
eliminated.extend(sorted(toRemove))
for name in toRemove:
del drivers[name]
return eliminated
Databrick โ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Bank of America is hiring Software Engineer
For 2023, 2024 grads
Location: Mumbai
https://careers.bankofamerica.com/en-us/job-detail/24035851/software-engineer-i-b-gbs-ind-multiple-locations
For 2023, 2024 grads
Location: Mumbai
https://careers.bankofamerica.com/en-us/job-detail/24035851/software-engineer-i-b-gbs-ind-multiple-locations
Bankofamerica
Bank of America Error Page
Please Try Again
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Innovaccer is hiring SDET
For 2021, 2022, 2023 grads
Location: Noida
https://job-boards.greenhouse.io/innovaccer/jobs/7625511002
For 2021, 2022, 2023 grads
Location: Noida
https://job-boards.greenhouse.io/innovaccer/jobs/7625511002
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
https://forms.office.com/Pages/ResponsePage.aspx?id=yXdC9f7aqkSFpHPVx8UkUE0Lt1Npr9tIvphtYFKvAWVUNjZPWkdLRDZBQUUwUE5TOU84WDBHUDdESS4u
Hitachi Systems India Pvt Ltd Hiring Database Administrator- Trainee
Face to Face Drive- Saturday, 21st Sept- Hitachi Systems India-Mumbai
Hitachi Systems India Pvt Ltd Hiring Database Administrator- Trainee
Face to Face Drive- Saturday, 21st Sept- Hitachi Systems India-Mumbai
Office
Please fill out this form
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Company Name: Mastercard
Role: Data Scientist Intern
Batch eligible: 2026 grads
Apply: https://mastercard.wd1.myworkdayjobs.com/en-US/Campus/job/Gurgaon-India/Data-Scientist-Intern--Summer-2025---India_R-228651
Role: Data Scientist Intern
Batch eligible: 2026 grads
Apply: https://mastercard.wd1.myworkdayjobs.com/en-US/Campus/job/Gurgaon-India/Data-Scientist-Intern--Summer-2025---India_R-228651
๐2
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
https://jobs.smartrecruiters.com/Eurofins/744000011450595-associate-software-engineer-sharepoint
Eurofins Hiring ASE - Sharepoint
B.E./ B. Tech (CS, IS, EC, EEE) / MCA/ MS /BSc (CS, IT)
0-12 months of IT Industry experience
60% aggregate in highest qualification (no backlogs)
Eurofins Hiring ASE - Sharepoint
B.E./ B. Tech (CS, IS, EC, EEE) / MCA/ MS /BSc (CS, IT)
0-12 months of IT Industry experience
60% aggregate in highest qualification (no backlogs)
Eurofins
Eurofins is looking for a Associate Software Engineer-Sharepoint in Bengaluru, Karnataka, India
POSITION TITLE: Associate Software Engineer:REPORTING TO: โCollaborative Platforms and IT Toolsโ Manager WORKING LOCATION: Bangalore, IndiaOBJECTIVE: Eurofins Collaborative Platforms and IT T...
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
https://www.amazon.jobs/jobs/2776777/it-support-associate-?cmpid=SPLICX0248M&utm_source=linkedin.com&utm_campaign=cxro&utm_medium=social_media&utm_content=job_posting&ss=paid
Amazon Hiring IT Support Associate
โข Bachelorโs degree/Diploma
โข 0 months to 18 months of work experience.
โข Good communication skills
PREFERRED QUALIFICATIONS
โข Basic Understanding of ITIL-Based Ticketing Tools and Monitoring Tools
โข Basic Understanding and troubleshooting skills on Network
Amazon Hiring IT Support Associate
โข Bachelorโs degree/Diploma
โข 0 months to 18 months of work experience.
โข Good communication skills
PREFERRED QUALIFICATIONS
โข Basic Understanding of ITIL-Based Ticketing Tools and Monitoring Tools
โข Basic Understanding and troubleshooting skills on Network
๐1