-
Algorithm Characteristics
List out the characteristics of an algorithm
-
Advantages of Circular Queue
Bring out the advantages of circular queue over linear queue
-
Quicksort Algorithm
Demonstrate the quicksort algorithm to sort a list of data elements
-
Traverse Binary Tree in Inorder
Design a conventional iterative algorithm to traverse a binary tree represented in linked lists in inorder.
-
Algorithm to Traverse Binary Tree
Design a conventional iterative algorithm to traverse a binary tree represented in linked lists in preorder.
-
Conventional Iterative Algorithm
Design a conventional iterative algorithm to traverse a binary tree represented in linked lists in postorder.
-
Importance of Algorithms
What is the importance of algorithms in the field of computer science?
-
Write an algorithm to read the date borrowed and present date.
A video club rents video for three days. Write an algorithm to read the date borrowed and the present date; calculate the number of days borrowed. If the number of days exceeds three days, compute the number of days overdue and overdue charge. Use a rate of $1.50 for everyday overdue or part overdue
-
Algorithm to input the price of a textbook
Write an algorithm to input the price of a textbook. Calculate the price and print the total cost of the book after 15% VAT is added
-
Degree Operations
Design an algorithm to show the different operations on degree
-
Distinct palindromic sub strings
I want to calculate number of DISTINCT palindromic substrings in a string.How to do it?
Like if aba is string the their are 3 distinct palindromic subsrings:{a,aba,b}
length of string could be 10^5 range.So i dont think O(n^2) solution will work.I want a algorithm to do this in less than O(n^2). -
Algorithm help
Create the flowchart and algorithm for a module that will prompt the user to enter the amount of cash they have in their pocket. The program should output “Not Enough” ($0 - $0.64), “Vending Machine” ($0.65 - $1.99), “Fast Food” ($2.00 - $4.99), “Cafeteria” ($5.00 - $14.99) or “Steak House” ($15 and up) depending on what the user can afford for lunch.
-
Calculate Number of Oil Pipes Required
Pipes are laid by an oil company. If the company has to laid down 3 km of pipe and each pipe is 25 metres long, calculate and print the number of pipes needed to cover the distance.
-
Read the Day and the Weather
A club plays cricket only on Sundays and only if it is not raining. Read the day and the weather and "Game on" if the weather is good and the day is Sunday, or "Play Suspended" if it is not Sunday and it is raining.
-
-
Book Index Rare Order
A book collector has a special requirement. He has a book which contains a letter with English alphabets. But the sequence of letters is not the standard English. i.e. the alphabet sequence are not A,B,C.....Z.
He has to find the letter sequence from the Index for the book. What could be the right algorithm for this?
Sample Input -
Suppose these are the below Indexes... -
Algorithm to print count and possible string outcomes of a given input string
Write an Efficient algorithm to print count and possible string outcomes of a given input string by retaining order and considering all characters during this process
Problem: given a input string as "0000" and following input scheme for the zeroes, print the possible outcomes by retaining order of the characters. input scheme: a "0" b "00" c "000" d "0000" example: "aaaa" is one string... -
Intersection of two convex polygons
Suppose that you are given m convex polygons P1; P2; : : : ; Pm in the plane. Let ni denote the
number of vertices on Pi and n =
Pm
i=1 ni. The vertices of each polygon is listed in counter-
clockwise order, starting at the leftmost vertex of Pi (that is, the one with the smallest x-
coordinate). Two polygons Pi and Pj are said to intersect if they contain any point in... -
Game of Jack Straws
In the game of Jack Straws, a number of plastic or wooden "straws" are dumped on the table and players try to remove them one-by-one without disturbing the other straws. In the question here, we are concerned with the following, related problem: First n straws are dumped on the table. Next, for every pair of straws, we want to determine if the straws are connected by a path of touching straws. In other...
-
Topological Sort Algorithm
Are there any topological sorting algorithms that, given a binary matrix A, (1) find the number of distinct rows of A and (2) for any row find the set of all equal rows? Can you give me some references of where I can find them?
Algorithm Questions
Ans