Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
โ๏ธRoblox Off Campus Drive 2024 | Software Engineer - New Graduate | Rs. 1.26 Croreโ๏ธ
๐จโ๐ป Job Role : Software Engineer
๐Qualification : B.E/B.Tech
๐Batch : New Graduate
๐ฐSalary : Rs. 1.26 Crore
https://careers.roblox.com/jobs/6086753?gh_jid=6086753&gh_src=71e9c9571us
๐จโ๐ป Job Role : Software Engineer
๐Qualification : B.E/B.Tech
๐Batch : New Graduate
๐ฐSalary : Rs. 1.26 Crore
https://careers.roblox.com/jobs/6086753?gh_jid=6086753&gh_src=71e9c9571us
Roblox Careers
Careers Homepage
We are building the future of human connection and communication. Learn more about our culture, teams and view all open jobs.
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Frontend required for a specific task
To develop a single landing page for product based company
Dm him with the best piece of work
@kalihaxor
To develop a single landing page for product based company
Dm him with the best piece of work
@kalihaxor
โค1
#include <iostream>
#include <vector>
using namespace std;
vector<int> frequencyOfMaxValue(vector<int>& numbers, vector<int>& queries) {
int n = numbers.size();
vector<int> answer(n, -1);
int maxvalue = -1;
int count = 1;
for (int i = n - 1; i >= 0; --i) {
if (numbers[i] == maxvalue) {
count++;
} else if (numbers[i] > maxvalue) {
maxvalue = numbers[i];
count = 1;
}
answer[i] = count;
}
vector<int> result;
for (int index : queries) {
result.push_back(answer[index - 1]);
}
return result;
}
Frequency ofMaxValue
Wells fargoโ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
#include <bits/stdc++.h>
using namespace std;
vector<int> getPopularityOrder(vector<vector<int>> song_preferences) {
int n = song_preferences[0].size();
vector<vector<int>> boxScore(n, vector<int>(n, 0));
for (const vector<int>& pref : song_preferences) {
for (int i = 0; i < pref.size() - 1; i++) {
for (int j = i + 1; j < pref.size(); j++) {
boxScore[pref[i]][pref[j]] += 1;
}
}
}
vector<array<int, 2>> wins(n, {0, 0});
for (int i = 0; i < n; i++) {
wins[i][0] = i;
for (int j = i + 1; j < n; j++) {
int score = boxScore[i][j] - boxScore[j][i];
if (score >= 0) {
wins[i][1]++;
} else {
wins[j][1]++;
}
}
}
sort(wins.begin(), wins.end(), [](const array<int, 2>& a, const array<int, 2>& b) {
if (a[1] == b[1]) {
return a[0] < b[0];
} else {
return b[1] < a[1];
}
});
vector<int> result;
for (const auto& win : wins) {
result.emplace_back(win[0]);
}
return result;
}
Songs Popularity
Wells Fargo โ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
#include <iostream> #include <vector> using namespace std; vector<int> frequencyOfMaxValue(vector<int>& numbers, vector<int>& queries) { int n = numbers.size(); vector<int> answer(n, -1); int maxvalue = -1; int count = 1; โฆ
def find_smallest_k(mat, n):
for k in range(n):
row_condition = all(mat[k][j] == 0 for j in range(n) if j != k)
column_condition = all(mat[i][k] == 1 for i in range(n) if i != k)
if row_condition and column_condition:
return k
return -1
n = int(input())
mat = []
for _ in range(n):
mat.append(list(map(int, input().split())))
result = find_smallest_k(mat, n)
print(result)
Samsung โ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
Photo
class Node:
def __init__(self, key):
self.data = key
self.left = None
self.right = None
def build_tree(level_order):
if not level_order or level_order[0] == -1:
return None
iter_order = iter(level_order)
root = Node(next(iter_order))
queue = [root]
while queue:
current_node = queue.pop(0)
left_value = next(iter_order, -1)
right_value = next(iter_order, -1)
if left_value != -1:
current_node.left = Node(left_value)
queue.append(current_node.left)
if right_value != -1:
current_node.right = Node(right_value)
queue.append(current_node.right)
return root
def largest_bst_subtree(root):
def post_order(node):
if not node:
return (float('inf'), float('-inf'), 0, True)
left_min, left_max, left_size, left_is_bst = post_order(node.left)
right_min, right_max, right_size, right_is_bst = post_order(node.right)
if left_is_bst and right_is_bst and left_max < node.data < right_min:
total_size = left_size + right_size + 1
return (min(left_min, node.data), max(right_max, node.data), total_size, True)
else:
return (0, 0, max(left_size, right_size), False)
return post_order(root)[2]
input_list = list(map(int, input().split()))
height = input_list[0]
level_order = input_list[1:]
root = build_tree(level_order)
if not root:
print(-1)
else:
result = largest_bst_subtree(root)
print(result)
BST in binary Tree
Samsung โ
def minStrength(matrix):
if not matrix or not matrix[0]:
return 0
rows, cols = len(matrix), len(matrix[0])
dp = [0] * cols
dp[-1] = 1 if matrix[-1][-1] > 0 else -matrix[-1][-1] + 1
for j in range(cols - 2, -1, -1):
dp[j] = max(dp[j + 1] - matrix[-1][j], 1)
for i in range(rows - 2, -1, -1):
dp[-1] = max(dp[-1] - matrix[i][-1], 1)
for j in range(cols - 2, -1, -1):
min_path = min(dp[j], dp[j + 1])
dp[j] = max(min_path - matrix[i][j], 1)
return dp[0]
Samsung โ
import heapq
def finalIndex(N, A):
dist = [float('inf')] * (N + 2)
dist[N] = 1
dist[N + 1] = 0
pq = [(1, N)]
while pq:
d, node = heapq.heappop(pq)
if d > dist[node]:
continue
if node == 1:
break
prev = node - 1
if prev >= 1 and d + 1 < dist[prev]:
dist[prev] = d + 1
heapq.heappush(pq, (dist[prev], prev))
prev = A.index(node) + 1
if d + 1 < dist[prev]:
dist[prev] = d + 1
heapq.heappush(pq, (dist[prev], prev))
return sum(dist[1:N+1])
Final Index - Samsungโ
#include <bits/stdc++.h>
using namespace std;
class UnionFind {
public:
UnionFind(int n) : parent(n), rank(n, 0) {
for (int i = 0; i < n; ++i) {
parent[i] = i;
}
}
int find(int u) {
if (parent[u] != u) {
parent[u] = find(parent[u]);
}
return parent[u];
}
void unionSet(int u, int v) {
int rootU = find(u);
int rootV = find(v);
if (rootU != rootV) {
if (rank[rootU] > rank[rootV]) {
parent[rootV] = rootU;
} else if (rank[rootU] < rank[rootV]) {
parent[rootU] = rootV;
} else {
parent[rootV] = rootU;
++rank[rootU];
}
}
}
bool sameSet(int u, int v) {
return find(u) == find(v);
}
private:
vector<int> parent;
vector<int> rank;
};
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n, m1, m2;
cin >> n >> m1 >> m2;
UnionFind ufAlice(n + 1);
UnionFind ufBob(n + 1);
vector<pair<int, int>> connectionsAlice(m1);
vector<pair<int, int>> connectionsBob(m2);
for (int i = 0; i < m1; ++i) {
int u, v;
cin >> u >> v;
connectionsAlice[i] = {u, v};
ufAlice.unionSet(u, v);
}
for (int i = 0; i < m2; ++i) {
int u, v;
cin >> u >> v;
connectionsBob[i] = {u, v};
ufBob.unionSet(u, v);
}
int maxConnections = 0;
for (int u = 1; u <= n; ++u) {
for (int v = u + 1; v <= n; ++v) {
if (!ufAlice.sameSet(u, v) && !ufBob.sameSet(u, v)) {
maxConnections++;
ufAlice.unionSet(u, v);
ufBob.unionSet(u, v);
}
}
}
cout << maxConnections << endl;
return 0;
}
```
``` Maximizing network connections in dual regions.โ
c++
#include <bits/stdc++.h>
using namespace std;
#define ll long long
ll mod = 1e9 + 7, cc_total = 0;
void dfs(vector<ll> adj[], vector<bool> &visited, ll src)
{
if (visited[src])
return;
cc_total++;
// cout << src << " " << cc_total << " vis\n";
visited[src] = true;
for (auto i : adj[src])
{
dfs(adj, visited, i);
}
}
void solve()
{
int n, m, x, y, total = 0, cap = 1;
cin >> n >> m;
vector<ll> adj[n + 1];
vector<bool> visited(n + 1, false);
// for (int i = 1; i <= n; i++)
// {
// adj[i].push_back(i);
// }
for (int i = 0; i < m; i++)
{
cin >> x >> y;
adj[x].push_back(y);
adj[y].push_back(x); // for undirected
}
for (int j=1; j<=n; j++)
{
// for (auto j : i)
{
if (!visited[j])
{
cc_total = 0;
dfs(adj, visited, j);
total++;
cap = (cc_total*cap)%mod;
total %= mod;
// cout << endl;
cc_total = 0;
}
}
}
cout << total << " " << cap << "\n";
}
int main()
{
int t = 1;
// #ifndef ONLINE_JUDGE
// freopen("input.txt", "r", stdin);
// freopen("output.txt", "w", stdout);
// #endif
cin >> t;
while (t--)
{
solve();
}
return 0;
}
Fire Escape Routesโ
#include <bits/stdc++.h>
using namespace std;
int solve(const string& str) {
if (str.empty()) return -2;
int maxInt = -1;
int currentNumber = 0;
bool hasNumber = false;
for (char ch : str) {
if (isdigit(ch)) {
currentNumber = currentNumber * 10 + (ch - '0');
hasNumber = true;
} else {
if (hasNumber) {
maxInt = max(maxInt, currentNumber);
currentNumber = 0;
hasNumber = false;
}
}
}
if (hasNumber) {
maxInt = max(maxInt, currentNumber);
}
return maxInt == -1 ? -1 : maxInt;
}
int main() {
int n;
cin >> n;
cin.ignore();
string str;
getline(cin, str);
cout << solve(str) << endl;
return 0;
}
identify maxium integere in string โ
๐๐ฆ ๐๐น๐ด๐ผ ๐ป ๐ ใ๐๐ผ๐บ๐ฝ๐ฒ๐๐ถ๐๐ถ๐๐ฒ ๐ฃ๐ฟ๐ผ๐ด๐ฟ๐ฎ๐บ๐บ๐ถ๐ป๐ดใ
import heapq def finalIndex(N, A): dist = [float('inf')] * (N + 2) dist[N] = 1 dist[N + 1] = 0 pq = [(1, N)] while pq: d, node = heapq.heappop(pq) if d > dist[node]: continue if node ==โฆ
def solve(N, A):
dp = [float('inf')] * (N + 2)
dp[N + 1] = 0
for i in range(N, 0, -1):
dp[i] = 1 + min(dp[i + 1], dp[A[i - 1]])
return sum(dp[1:N+1])
N = int(input())
A = list(map(int, input().split()))
print(solve(N, A))
Final index โ
dp = [float('inf')] * (N + 2)
dp[N + 1] = 0
for i in range(N, 0, -1):
dp[i] = 1 + min(dp[i + 1], dp[A[i - 1]])
return sum(dp[1:N+1])
N = int(input())
A = list(map(int, input().split()))
print(solve(N, A))
Final index โ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
MongoDB is hiring Data Engineer intern
For 2024, 2025 grads
Location: Gurugram
https://www.mongodb.com/careers/jobs/6075710
For 2024, 2025 grads
Location: Gurugram
https://www.mongodb.com/careers/jobs/6075710
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Murf AI is hiring SWE
For 2021, 2022, 2023 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3997731217
For 2021, 2022, 2023 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3997731217
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Southworks is hiring SWE(Full-stack)
For 2021, 2022, 2023 grads
Location: Remote
https://boards.eu.greenhouse.io/southworks/jobs/4374587101
For 2021, 2022, 2023 grads
Location: Remote
https://boards.eu.greenhouse.io/southworks/jobs/4374587101
job-boards.eu.greenhouse.io
SOUTHWORKS
<h2 data-type="unstyled" data-id="ab490d97-ae9b-43df-87cd-bfc59d954ec4"><strong data-type="bold">Come shape the future of tech </strong></h2>
<p class="x_xmsonormal"><strong>SOUTHWORKS is the pioneer of Development on Demand</strong>, the new model for nearshoreโฆ
<p class="x_xmsonormal"><strong>SOUTHWORKS is the pioneer of Development on Demand</strong>, the new model for nearshoreโฆ
Forwarded from OffCampus Jobs | OnCampus Jobs | Daily Jobs Updates | Lastest Jobs | All Jobs | CSE Jobs | Fresher Jobs โฅ (Dushyant)
Securiti is hiring SDE
For 2023, 2024 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3995834639
For 2023, 2024 grads
Location: Bangalore
https://www.linkedin.com/jobs/view/3995834639
Linkedin
Securiti hiring Java Software Engineer in Bengaluru, Karnataka, India | LinkedIn
Posted 12:29:10 PM. Company Description Securiti is a pioneering company known for the Data Command Center, a platformโฆ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)
โค1