## C# | Graphics.DrawLine() Method | Set – 2

Graphics.DrawLine() Method is used to draw a line connecting the two points specified by the coordinate pairs. There are 4 methods in the overload list… Read More »

Graphics.DrawLine() Method is used to draw a line connecting the two points specified by the coordinate pairs. There are 4 methods in the overload list… Read More »

This method is used to releases all resources used by the current instance of the CharEnumerator class. The Dispose() method leaves the CharEnumerator in an… Read More »

Socket programming is a way of connecting two nodes on a network to communicate with each other. Basically, it is a one-way Client and Server… Read More »

Question: Write code in C# to Hash an array of keys and display them with their hash code. Answer: Hashtable is a widely used data… Read More »

ArrayList.CopyTo(Array, Int32) Method is used to copy the entire ArrayList to a compatible one-dimensional Array, starting at the specified index of the target array. Syntax:… Read More »

This method is used to return the hash code for this instance. Syntax: public override int GetHashCode (); Return Value: This method returns a 32-bit… Read More »

Given two sorted arrays and a number x, find the pair whose sum is closest to x and the pair has an element from each… Read More »

There are n stairs, a person standing at the bottom wants to reach the top. The person can climb either 1 stair or 2 stairs… Read More »

Given a text txt[0..n-1] and a pattern pat[0..m-1], write a function search(char pat[], char txt[]) that prints all occurrences of pat[] and its permutations (or… Read More »

Given a positive integer N, count all possible distinct binary strings of length N such that there are no consecutive 1’s. Examples: Input: N =… Read More »

Given an integer n, write a function that returns count of trailing zeroes in n!. Examples : Input: n = 5 Output: 1 Factorial of… Read More »

Catalan numbers are a sequence of natural numbers that occurs in many interesting counting problems like following. 1) Count the number of expressions containing n… Read More »

Given a 2D array, find the maximum sum subarray in it. For example, in the following 2D array, the maximum sum subarray is highlighted with… Read More »

Given a set of non-negative integers, and a value sum, determine if there is a subset of the given set with sum equal to given… Read More »

Given a graph and a source vertex in the graph, find shortest paths from source to all vertices in the given graph. Dijkstra’s algorithm is… Read More »