string solve(string S1, string S2) {
int L1 = S1.size();
int L2 = S2.size();
string S(L1 + L2 - 1, ' ');
for (int i = 0; i < L2; i++) {
if (S2[i] == 'T') {
for (int j = 0; j < L1; j++) {
S[i + j] = S1[j];
}
}
}
for (int i = 0; i < L1 + L2 - 1; i++) {
if (S[i] == ' ') {
S[i] = 'A';
}
}
for (int i = 0; i < L2; i++) {
if (S2[i] == 'T') {
for (int j = 0; j < L1; j++) {
if (S[i + j] != S1[j]) {
return "-1";
}
}
}
}
return S;
}
String generation Barclaysโ
int L1 = S1.size();
int L2 = S2.size();
string S(L1 + L2 - 1, ' ');
for (int i = 0; i < L2; i++) {
if (S2[i] == 'T') {
for (int j = 0; j < L1; j++) {
S[i + j] = S1[j];
}
}
}
for (int i = 0; i < L1 + L2 - 1; i++) {
if (S[i] == ' ') {
S[i] = 'A';
}
}
for (int i = 0; i < L2; i++) {
if (S2[i] == 'T') {
for (int j = 0; j < L1; j++) {
if (S[i + j] != S1[j]) {
return "-1";
}
}
}
}
return S;
}
String generation Barclaysโ
int getMinimumInversions(int n, vector<int> g_from, vector<int> g_to) {
vector<vector<int>> adj(n);
set<pair<int, int>> edge;
for (int i = 0; i < n - 1; ++i) {
int u = g_from[i], v = g_to[i];
u--, v--;
adj[u].push_back(v);
adj[v].push_back(u);
edge.insert({u, v});
}
int val = 0;
function<void(int, int)> dfs = [&](int cur, int par) {
for (int it : adj[cur]) {
if (it == par) continue;
if (!edge.count({cur, it})) {
val++;
}
dfs(it, cur);
}
};
dfs(0, -1);
int ans = val;
function<void(int, int, int)> rerooting_dfs = [&](int cur, int par, int v) {
ans = min(ans, v);
for (int it : adj[cur]) {
if (it == par) continue;
int new_val = v;
if (edge.count({cur, it})) {
new_val++;
} else {
new_val--;
}
rerooting_dfs(it, cur, new_val);
}
};
rerooting_dfs(0, -1, val);
return ans;
}
Minimum Reversal (Bny)โ
vector<vector<int>> adj(n);
set<pair<int, int>> edge;
for (int i = 0; i < n - 1; ++i) {
int u = g_from[i], v = g_to[i];
u--, v--;
adj[u].push_back(v);
adj[v].push_back(u);
edge.insert({u, v});
}
int val = 0;
function<void(int, int)> dfs = [&](int cur, int par) {
for (int it : adj[cur]) {
if (it == par) continue;
if (!edge.count({cur, it})) {
val++;
}
dfs(it, cur);
}
};
dfs(0, -1);
int ans = val;
function<void(int, int, int)> rerooting_dfs = [&](int cur, int par, int v) {
ans = min(ans, v);
for (int it : adj[cur]) {
if (it == par) continue;
int new_val = v;
if (edge.count({cur, it})) {
new_val++;
} else {
new_val--;
}
rerooting_dfs(it, cur, new_val);
}
};
rerooting_dfs(0, -1, val);
return ans;
}
Minimum Reversal (Bny)โ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
๐๐ฒ๐ป๐ฒ๐ฟ๐ฎ๐น ๐๐น๐ฒ๐ฐ๐๐ฟ๐ถ๐ฐ ๐ต๐ถ๐ฟ๐ถ๐ป๐ด ๐ฎ๐ป๐ฎ๐น๐๐๐ ๐ฝ๐ฟ๐ผ๐ณ๐ถ๐น๐ฒ.
Batch- 2022,2021 https://docs.google.com/forms/d/1r1E2SW8SKa3pDXWEh-zVkr1qbacjiJQO8BJWn5HpwTc/viewform?pli=1&pli=1&edit_requested=true
Batch- 2022,2021 https://docs.google.com/forms/d/1r1E2SW8SKa3pDXWEh-zVkr1qbacjiJQO8BJWn5HpwTc/viewform?pli=1&pli=1&edit_requested=true
Google Docs
General Electric hiring Analyst profile
Required Qualifications:
Bachelors in Technology, Computer Science, Computer Engineering, Information Systems, Information Management or related field
1-2 years of full time work experience
Desired Qualifications:
Prior intern, co-op, or research experienceโฆ
Bachelors in Technology, Computer Science, Computer Engineering, Information Systems, Information Management or related field
1-2 years of full time work experience
Desired Qualifications:
Prior intern, co-op, or research experienceโฆ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Toplyne is Hiring !!
Role: SDE Intern - Backend
Expected CTC: 45K-60K per month
Location: Bengaluru
Apply here- https://linkedin.com/jobs/view/sde-intern-backend-at-toplyne-3734848127/
Role: SDE Intern - Backend
Expected CTC: 45K-60K per month
Location: Bengaluru
Apply here- https://linkedin.com/jobs/view/sde-intern-backend-at-toplyne-3734848127/
Linkedin
Toplyne hiring SDE Intern - Backend in Bengaluru, Karnataka, India | LinkedIn
Posted 12:51:13 PM. ๐๐ป What is Toplyne? Toplyne the behavioral lead scoring platform Canva & Vercel uses to generateโฆSee this and similar jobs on LinkedIn.
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Company Name: ServiceNow
Role: Software Engineer
Batch eligible: 2023 and earlier grads only
Apply: https://bit.ly/3tnuZ0d
Role: Software Engineer
Batch eligible: 2023 and earlier grads only
Apply: https://bit.ly/3tnuZ0d
Software Engineer in Hyderabad | ServiceNow Careers
ServiceNow Careers is hiring a Software Engineer in Hyderabad. Review all of the job details and apply today!
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
MindTickle Hiring SDE Intern
Batch 2024
Link ๐
https://jobs.lever.co/mindtickle/46d88242-db9b-49fa-9d69-07dd25345bb5
Batch 2024
Link ๐
https://jobs.lever.co/mindtickle/46d88242-db9b-49fa-9d69-07dd25345bb5
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Linkedin
Sign Up | LinkedIn
500 million+ members | Manage your professional identity. Build and engage with your professional network. Access knowledge, insights and opportunities.
System Fails โ