Master technical and career interviews with structured answers—short definition, real examples, pitfalls, and how to answer in 60–90 seconds.
Short answer: LINQ Distinct()) Logic Use a HashSet to track seen elements. Add elements only if they are not already present. int[] arr = { 1, 2, 3, 2, 4, 1 }; HashSet<int> set = new HashSet<int>(); List<i…
Short answer: = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Explain a bit more Follow on: = b; b = temp; } return b; } Explanation: Iterative DP approach;…
Short answer: element appears twice public int SingleNonRepeated(int[] nums) { Example code int result = 0; foreach (int num in nums) { result ^= num; } return result; } Explanation: XOR of a number with itself is 0; XOR…
Short answer: public List<int> FindAnagrams(string s, string p) { List<int> result = new List<int>(); if (p.Length > s.Length) return result; int[] pCount = new int[26]; int[] sCount = new int[26]; F…
Short answer: public List<int> PrimeFactors(int n) { List<int> factors = new List<int>(); // Print the number of 2s that divide n while (n % 2 == 0) { factors.Add(2); n /= 2; } // n must be odd at this…
Short answer: public int FindKthLargest(int[] nums, int k) { return QuickSelect(nums, 0, nums.Length - 1, nums.Length - k); } private int QuickSelect(int[] nums, int left, int right, int kSmallest) { if (left == right) r…
Short answer: int UniquePaths(int m, int n) { int[,] dp = new int[m, n]; for (int i = 0; i < m; i++) dp[i, 0] = 1; for (int j = 0; j < n; j++) dp[0, j] = 1; for (int i = 1; i < m; i++) { for (int j = 1; j < n…
Short answer: void BFS(Dictionary<int, List<int>> graph, int start) { var visited = new HashSet<int>(); var queue = new Queue<int>(); queue.Enqueue(start); visited.Add(start); while (queue.Count &…
Short answer: public class TreeNode { public int val; public TreeNode left, right; public TreeNode(int x) { val = x; } } TreeNode prev = null; TreeNode head = null; TreeNode ConvertToDLL(TreeNode root) { if (root == null…
Short answer: public class MyQueue { private Stack<int> stackIn = new Stack<int>(); private Stack<int> stackOut = new Stack<int>(); // Enqueue: push into stackIn (O(1)) public void Enqueue(int x)…
Short answer: begins public class ListNode { Example code public int val; public ListNode next; public ListNode(int x) { val = x; next = null; } } ListNode DetectCycle(ListNode head) { if (head == null) return null; List…
Short answer: int MergeSortAndCount(int[] arr, int[] temp, int left, int right) { int invCount = 0; if (right > left) { int mid = (right + left) / 2; invCount += MergeSortAndCount(arr, temp, left, mid); invCount += Me…
Short answer: Algorithm int GCD(int a, int b) { Follow on: while (b != 0) { Example code int temp = b; b = a % b; a = temp; } return a; } Explanation: Repeatedly replace (a, b) with (b, a mod b) until b is 0; then a is t…
Short answer: void QuickSort(int[] arr, int low, int high) { Example code if (low < high) Follow on: { int pi = Partition(arr, low, high); QuickSort(arr, low, pi - 1); QuickSort(arr, pi + 1, high); } } int Partition(i…
Short answer: int Fibonacci(int n) { if (n <= 1) return n; int a = 0, b = 1; for (int i = 2; i <= n; i++) { int temp = a + b; a = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number…
Short answer: lternative using Brian Kernighan’s algorithm: public int CountSetBits(int n) { int count = 0; while (n != 0) { n &amp;= (n - 1); // Drops the lowest set bit count++; } return count; } Follow on: lternat…
Short answer: Feature Git TFVC Type Distributed Centralized History Full copy on each developer’s machine Stored on server Branching Lightweight and fast Heavier and slower Offline work Possible Needs connection Common u…
Short answer: What tasks are commonly used in .NET build pipelines? Answer: Common tasks: UseDotNet@2 → Installs .NET SDK. NuGetCommand@2 → Restores NuGet packages. DotNetCoreCLI@2 → Builds, tests, and publishes your app…
Short answer: company using Jenkins moves to Azure DevOps to unify code and pipelines. They convert Jenkinsfile logic to YAML, using tasks like DotNetCoreCLI@2 and zureWebApp@1. Real-world example (ShopNest) ShopNest’s Y…
Short answer: .NET Core API gets built automatically when code is pushed to main. If tests pass, it’s deployed to staging — and after approval, to production. Real-world example (ShopNest) A “Add UPI payment” feature is…
Short answer: Zero-downtime means your API stays live while deploying new versions. Ways to achieve it: Use Azure App Service Deployment Slots (swap after warm-up). Real-world example (ShopNest) ShopNest’s YAML pipeline…
Short answer: How do you restore NuGet packages in a build pipeline? Answer: Use either: script: dotnet restore or task: NuGetCommand@2 inputs: command: 'restore' This pulls dependencies from NuGet.org or an internal fee…
Short answer: How do you perform rollback in case of a failed deployment? Explain a bit more Answer: There are several ways: Use deployment slots — just swap back to the previous slot. Re-deploy a previous successful rel…
Short answer: How do you run unit tests and publish test results in a pipeline? Answer: You use the DotNetCoreCLI@2 task with test command and publish results. Example (YAML): task: DotNetCoreCLI@2 inputs: command: 'test…
Short answer: What are service connections in Azure DevOps? Answer: A service connection is a secure link between Azure DevOps and external systems (like Azure, AWS, GitHub, or Docker Hub). Example: If your pipeline need…
C# Coding Interview C# Programming Tutorial · Coding Scenarios
Short answer: LINQ Distinct()) Logic Use a HashSet to track seen elements. Add elements only if they are not already present. int[] arr = { 1, 2, 3, 2, 4, 1 }; HashSet<int> set = new HashSet<int>(); List<int> result = new List<int>(); foreach (int num in arr) { if (!set.Contains(num)) { set.Add(num); result.Add(num); } } Why this works: HashSet ensures uniqueness with O(1) lookup.
LINQ Distinct()) Logic Use a HashSet to track seen elements. Add elements only if they are not already present. int[] arr = { 1, 2, 3, 2, 4, 1 };
HashSet<int> set = new HashSet<int>();
List<int> result = new List<int>();
foreach (int num in arr)
{
if (!set.Contains(num))
{ set.Add(num); result.Add(num); }
} Why this works: HashSet ensures uniqueness with O(1) lookup.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous.
Follow on: = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Follow on: = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Follow on: = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Follow on:
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: element appears twice public int SingleNonRepeated(int[] nums) {
int result = 0;
foreach (int num in nums) {
result ^= num;
}
return result;
} Explanation: XOR of a number with itself is 0; XOR with 0 is the number. So duplicates cancel out, leaving the unique number. Follow on:
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: public List<int> FindAnagrams(string s, string p) { List<int> result = new List<int>(); if (p.Length > s.Length) return result; int[] pCount = new int[26]; int[] sCount = new int[26]; Follow on: for (int i = 0; i < p.Length; i++) { pCount[p[i] - 'a']++; sCount[s[i] - 'a']++; } if (Enumerable.SequenceEqual(pCount, sCount)) result.Add(0); for (int i = p.Length; i < s.Length; i++) { sCount[s[i] - 'a']++; sCount[s[i - p.
Length] - 'a']--; if (Enumerable.SequenceEqual(pCount, sCount)) result.Add(i - p.Length + 1); } return result; } Explanation: Sliding window with frequency count arrays for the pattern and current window.
public List<int> FindAnagrams(string s, string p) {
List<int> result = new List<int>();
if (p.Length > s.Length) return result;
int[] pCount = new int[26];
int[] sCount = new int[26]; Follow on: for (int i = 0; i < p.Length; i++) { pCount[p[i] - 'a']++; sCount[s[i] - 'a']++; }
if (Enumerable.SequenceEqual(pCount, sCount)) result.Add(0); for (int i = p.Length; i < s.Length; i++) { sCount[s[i] - 'a']++; sCount[s[i - p.Length] - 'a']--; if (Enumerable.SequenceEqual(pCount, sCount)) result.Add(i - p.Length + 1); }
return result;
} Explanation: Sliding window with frequency count arrays for the pattern and current window.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: public List<int> PrimeFactors(int n) { List<int> factors = new List<int>(); // Print the number of 2s that divide n while (n % 2 == 0) { factors.Add(2); n /= 2; } // n must be odd at this point for (int i = 3; i * i <= n; i += 2) { while (n % i == 0) { factors.Add(i); n /= i; } } Follow on: // If n is a prime number > 2 if (n > 2) { factors.Add(n); } return factors; } Explanation: We repeatedly divide by 2, then…
check odd factors up to √n. If leftover n > 2, it's prime.
public List<int> PrimeFactors(int n) {
List<int> factors = new List<int>(); // Print the number of 2s that divide n while (n % 2 == 0) { factors.Add(2); n /= 2;
} // n must be odd at this point for (int i = 3; i * i <= n; i += 2) { while (n % i == 0) { factors.Add(i); n /= i;
}
} Follow on: // If n is a prime number > 2 if (n > 2) { factors.Add(n); }
return factors;
} Explanation: We repeatedly divide by 2, then check odd factors up to √n. If leftover n > 2, it's prime.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: public int FindKthLargest(int[] nums, int k) { return QuickSelect(nums, 0, nums.Length - 1, nums.Length - k); } private int QuickSelect(int[] nums, int left, int right, int kSmallest) { if (left == right) return nums[left]; int pivotIndex = Partition(nums, left, right); if (kSmallest == pivotIndex) return nums[kSmallest]; else if (kSmallest < pivotIndex) return QuickSelect(nums, left, pivotIndex - 1, kSmallest);…
else return QuickSelect(nums, pivotIndex + 1, right, kSmallest); } private int Partition(int[] nums, int left, int right) { int pivot = nums[right]; int i = left; for (int j = left; j < right; j++) { if (nums[j] <= pivot) { Swap(nums, i, j); i++; } } Swap(nums, i, right); return i; } private void Swap(int[] nums, int i, int j) { int temp = nums[i]; nums[i] = nums[j]; nums[j] = temp; } Follow on: Explanation: Quickselect partitions the array like Quicksort and recursively searches for the kth smallest element. Here, nums.Length - k gives the kth largest.
public int FindKthLargest(int[] nums, int k) {
return QuickSelect(nums, 0, nums.Length - 1, nums.Length - k);
}
private int QuickSelect(int[] nums, int left, int right, int kSmallest) { if (left == right) return nums[left];
int pivotIndex = Partition(nums, left, right);
if (kSmallest == pivotIndex)
return nums[kSmallest]; else if (kSmallest < pivotIndex) return QuickSelect(nums, left, pivotIndex - 1, kSmallest); else return QuickSelect(nums, pivotIndex + 1, right, kSmallest);
}
private int Partition(int[] nums, int left, int right) {
int pivot = nums[right];
int i = left;
for (int j = left; j < right; j++) {
if (nums[j] <= pivot) { Swap(nums, i, j); i++; }
} Swap(nums, i, right); return i;
}
private void Swap(int[] nums, int i, int j) {
int temp = nums[i];
nums[i] = nums[j];
nums[j] = temp;
} Follow on: Explanation: Quickselect partitions the array like Quicksort and recursively searches for the kth smallest element. Here, nums.Length - k gives the kth largest.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: int UniquePaths(int m, int n) { int[,] dp = new int[m, n]; for (int i = 0; i < m; i++) dp[i, 0] = 1; for (int j = 0; j < n; j++) dp[0, j] = 1; for (int i = 1; i < m; i++) { for (int j = 1; j < n; j++) { dp[i, j] = dp[i - 1, j] + dp[i, j - 1]; } } return dp[m - 1, n - 1]; } Follow on:
int UniquePaths(int m, int n) {
int[,] dp = new int[m, n];
for (int i = 0; i < m; i++) dp[i, 0] = 1;
for (int j = 0; j < n; j++) dp[0, j] = 1;
for (int i = 1; i < m; i++) {
for (int j = 1; j < n; j++) {
dp[i, j] = dp[i - 1, j] + dp[i, j - 1];
}
}
return dp[m - 1, n - 1];
} Follow on:
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: void BFS(Dictionary<int, List<int>> graph, int start) { var visited = new HashSet<int>(); var queue = new Queue<int>(); queue.Enqueue(start); visited.Add(start); while (queue.Count > 0) { int node = queue.Dequeue(); Console.WriteLine(node); foreach (var neighbor in graph[node]) { if (!visited.Contains(neighbor)) { visited.Add(neighbor); queue.Enqueue(neighbor); } } } } Explanation: Classic BFS using a queue and…
void BFS(Dictionary<int, List<int>> graph, int start) { var visited = new HashSet<int>();
var queue = new Queue<int>(); queue.Enqueue(start); visited.Add(start); while (queue.Count > 0) { int node = queue.Dequeue(); Console.WriteLine(node); foreach (var neighbor in graph[node]) {
if (!visited.Contains(neighbor)) { visited.Add(neighbor); queue.Enqueue(neighbor); }
}
}
} Explanation: Classic BFS using a queue and visited set.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: public class TreeNode { public int val; public TreeNode left, right; public TreeNode(int x) { val = x; } } TreeNode prev = null; TreeNode head = null; TreeNode ConvertToDLL(TreeNode root) { if (root == null) return null; ConvertToDLL(root.left); if (prev == null) { head = root; // first node becomes head } else { root.left = prev; Follow on: prev.right = root; } prev = root; ConvertToDLL(root.right); return head; }…
Explanation: Inorder traversal connects nodes as doubly linked list by linking current with previous node.
public class TreeNode {
public int val;
public TreeNode left, right;
public TreeNode(int x) { val = x; }
}
TreeNode prev = null;
TreeNode head = null; TreeNode ConvertToDLL(TreeNode root) { if (root == null) return null; ConvertToDLL(root.left); if (prev == null) {
head = root; // first node becomes head } else { root.left = prev; Follow on: prev.right = root;
}
prev = root; ConvertToDLL(root.right); return head;
} Explanation: Inorder traversal connects nodes as doubly linked list by linking current with previous node.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: public class MyQueue { private Stack<int> stackIn = new Stack<int>(); private Stack<int> stackOut = new Stack<int>(); // Enqueue: push into stackIn (O(1)) public void Enqueue(int x) { stackIn.Push(x); } // Dequeue: if stackOut empty, pour all from stackIn to stackOut, then pop (amortized O(1)) public int Dequeue() { if (stackOut.Count == 0) { while (stackIn.Count > 0) { stackOut.Push(stackIn.Pop()); } } return…
stackOut.Pop(); } public int Peek() { if (stackOut.Count == 0) { while (stackIn.Count > 0) { stackOut.Push(stackIn.Pop()); } } return stackOut.Peek(); } public bool IsEmpty() { return stackIn.Count == 0 && stackOut.Count == 0; } } Follow on: Explanation: Two stacks are used: stackIn for enqueue, stackOut for dequeue. Elements are transferred only when needed, making both operations amortized O(1).
public class MyQueue {
private Stack<int> stackIn = new Stack<int>();
private Stack<int> stackOut = new Stack<int>(); // Enqueue: push into stackIn (O(1)) public void Enqueue(int x) { stackIn.Push(x); } // Dequeue: if stackOut empty, pour all from stackIn to stackOut, then pop (amortized O(1)) public int Dequeue() {
if (stackOut.Count == 0) { while (stackIn.Count > 0) { stackOut.Push(stackIn.Pop()); }
}
return stackOut.Pop();
}
public int Peek() {
if (stackOut.Count == 0) { while (stackIn.Count > 0) { stackOut.Push(stackIn.Pop()); }
}
return stackOut.Peek();
}
public bool IsEmpty() {
return stackIn.Count == 0 && stackOut.Count == 0;
}
} Follow on: Explanation: Two stacks are used: stackIn for enqueue, stackOut for dequeue. Elements are transferred only when needed, making both operations amortized O(1).
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: begins public class ListNode {
public int val;
public ListNode next;
public ListNode(int x) { val = x; next = null; }
}
ListNode DetectCycle(ListNode head) {
if (head == null) return null;
ListNode slow = head, fast = head; Follow on: // Detect cycle using Floyd's Tortoise and Hare while (fast != null && fast.next != null) { slow = slow.next;
fast = fast.next.next;
if (slow == fast) { // cycle detected
ListNode ptr = head; while (ptr != slow) { ptr = ptr.next;
slow = slow.next;
}
return ptr; // start node of cycle
}
}
return null; // no cycle
} Explanation: First detect cycle meeting point with two pointers. Then find start node by moving one pointer from head and one from meeting point until they meet.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: int MergeSortAndCount(int[] arr, int[] temp, int left, int right) { int invCount = 0; if (right > left) { int mid = (right + left) / 2; invCount += MergeSortAndCount(arr, temp, left, mid); invCount += MergeSortAndCount(arr, temp, mid + 1, right); invCount += Merge(arr, temp, left, mid + 1, right); } return invCount; } int Merge(int[] arr, int[] temp, int left, int mid, int right) { int i = left, j = mid, k = left;…
int invCount = 0; while (i <= mid - 1 && j <= right) { if (arr[i] <= arr[j]) temp[k++] = arr[i++]; else { temp[k++] = arr[j++]; invCount += (mid - i); // Count inversions } } while (i <= mid - 1) temp[k++] = arr[i++]; Follow on: while (j <= right) temp[k++] = arr[j++]; for (int idx = left; idx <= right; idx++) arr[idx] = temp[idx]; return invCount; } Explanation: Using a modified merge sort to count pairs where arr[i] > arr[j] for i < j efficiently.
int MergeSortAndCount(int[] arr, int[] temp, int left, int right)
{
int invCount = 0;
if (right > left)
{
int mid = (right + left) / 2;
invCount += MergeSortAndCount(arr, temp, left, mid);
invCount += MergeSortAndCount(arr, temp, mid + 1, right);
invCount += Merge(arr, temp, left, mid + 1, right);
}
return invCount;
}
int Merge(int[] arr, int[] temp, int left, int mid, int right)
{
int i = left, j = mid, k = left;
int invCount = 0; while (i <= mid - 1 && j <= right) {
if (arr[i] <= arr[j])
temp[k++] = arr[i++]; else {
temp[k++] = arr[j++];
invCount += (mid - i); // Count inversions
}
} while (i <= mid - 1) temp[k++] = arr[i++]; Follow on: while (j <= right) temp[k++] = arr[j++];
for (int idx = left; idx <= right; idx++)
arr[idx] = temp[idx];
return invCount;
} Explanation: Using a modified merge sort to count pairs where arr[i] > arr[j] for i < j efficiently.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: Algorithm int GCD(int a, int b) { Follow on: while (b != 0) {
int temp = b;
b = a % b;
a = temp;
}
return a;
} Explanation: Repeatedly replace (a, b) with (b, a mod b) until b is 0; then a is the GCD.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: void QuickSort(int[] arr, int low, int high) {
if (low < high) Follow on: {
int pi = Partition(arr, low, high); QuickSort(arr, low, pi - 1); QuickSort(arr, pi + 1, high); }
}
int Partition(int[] arr, int low, int high)
{
int pivot = arr[high];
int i = low - 1;
for (int j = low; j < high; j++)
{
if (arr[j] < pivot)
{ i++; (arr[i], arr[j]) = (arr[j], arr[i]);
}
}
(arr[i + 1], arr[high]) = (arr[high], arr[i + 1]);
return i + 1;
} Explanation: Choose last element as pivot, partition array so left < pivot < right, recursively sort subarrays.
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: int Fibonacci(int n) { if (n <= 1) return n; int a = 0, b = 1; for (int i = 2; i <= n; i++) { int temp = a + b; a = b; b = temp; } return b; } Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Follow on:
int Fibonacci(int n)
{
if (n <= 1) return n;
int a = 0, b = 1;
for (int i = 2; i <= n; i++)
{
int temp = a + b;
a = b;
b = temp;
}
return b;
} Explanation: Iterative DP approach; each Fibonacci number is sum of two previous. Follow on:
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
C# Coding Interview C# Programming Tutorial · Coding
Short answer: lternative using Brian Kernighan’s algorithm: public int CountSetBits(int n) { int count = 0; while (n != 0) { n &= (n - 1); // Drops the lowest set bit count++; } return count; } Follow on: lternative using Brian Kernighan’s algorithm: public int CountSetBits(int n) { int count = 0; while (n != 0) { n &= (n - 1); // Drops… the lowest set bit…… lternative using Brian Kernighan’s algorithm: public int…
CountSetBits(int n) { int count = 0; while (n != 0) { n &= (n - 1); // Drops the lowest set bit count++; } return count; } Follow on: lternative using Brian Kernighan’s algorithm: public int CountSetBits(int n) { int count = 0; while (n != 0) { n &= (n - 1); // Drops… the lowest set bit count++; } return count; } Follow on:
In coding rounds, state complexity aloud, write a clear ShopNest-flavored example (orders, carts), then handle edge cases (empty list, null, overflow).
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: Feature Git TFVC Type Distributed Centralized History Full copy on each developer’s machine Stored on server Branching Lightweight and fast Heavier and slower Offline work Possible Needs connection Common use Modern DevOps projects Legacy TFS projects Example: In Git, you can commit locally even offline on a flight — with TFVC, you’d need… server ccess.
Git is now the default in Azure DevOps for flexibility and collaboration.
Azure DevOps holds ShopNest repos, boards, and release pipelines in one place so build + deploy stay repeatable.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: What tasks are commonly used in .NET build pipelines? Answer: Common tasks: UseDotNet@2 → Installs .NET SDK. NuGetCommand@2 → Restores NuGet packages. DotNetCoreCLI@2 → Builds, tests, and publishes your app. PublishBuildArtifacts@1 → Stores your compiled output. Example: A .NET Core pipeline may use: task: DotNetCoreCLI@2 inputs: command: 'build'
ShopNest’s YAML pipeline builds on every PR, runs unit tests, then deploys to a staging slot on main-branch merges.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: company using Jenkins moves to Azure DevOps to unify code and pipelines. They convert Jenkinsfile logic to YAML, using tasks like DotNetCoreCLI@2 and zureWebApp@1.
ShopNest’s YAML pipeline builds on every PR, runs unit tests, then deploys to a staging slot on main-branch merges.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: .NET Core API gets built automatically when code is pushed to main. If tests pass, it’s deployed to staging — and after approval, to production.
A “Add UPI payment” feature is a User Story with Tasks. Testers link bugs to the same work item for traceability.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: Zero-downtime means your API stays live while deploying new versions. Ways to achieve it: Use Azure App Service Deployment Slots (swap after warm-up).
ShopNest’s YAML pipeline builds on every PR, runs unit tests, then deploys to a staging slot on main-branch merges.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: How do you restore NuGet packages in a build pipeline? Answer: Use either: script: dotnet restore or task: NuGetCommand@2 inputs: command: 'restore' This pulls dependencies from NuGet.org or an internal feed. Example: If your project uses private packages, you can add a NuGet service connection or Azure Artifacts feed to authenticate.
ShopNest’s YAML pipeline builds on every PR, runs unit tests, then deploys to a staging slot on main-branch merges.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: How do you perform rollback in case of a failed deployment?
Answer: There are several ways: Use deployment slots — just swap back to the previous slot. Re-deploy a previous successful release in Azure DevOps. Use versioned artifacts — keep your last working package and redeploy it. Example: If your new API build breaks production, you can quickly redeploy the previous successful release version from Azure DevOps → Releases → “Redeploy”.
Azure DevOps holds ShopNest repos, boards, and release pipelines in one place so build + deploy stay repeatable.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: How do you run unit tests and publish test results in a pipeline? Answer: You use the DotNetCoreCLI@2 task with test command and publish results. Example (YAML): task: DotNetCoreCLI@2 inputs: command: 'test' projects: '**/*Tests.csproj' publishTestResults: true Azure Pipelines will then display test results (passed, failed, duration) in the build summary.
ShopNest’s YAML pipeline builds on every PR, runs unit tests, then deploys to a staging slot on main-branch merges.
Azure DevOps Microsoft Azure Tutorial · DevOps
Short answer: What are service connections in Azure DevOps? Answer: A service connection is a secure link between Azure DevOps and external systems (like Azure, AWS, GitHub, or Docker Hub). Example: If your pipeline needs to deploy code to Azure App Service, you create an Azure Resource Manager service connection. It stores credentials securely so the pipeline can deploy automatically.
Azure DevOps holds ShopNest repos, boards, and release pipelines in one place so build + deploy stay repeatable.