Comp. sci algorithms, Data Structure & Algorithms

1. develop an algorithm which reads two decimal numbers x and y and determines and prints out wether x>y or y>x. the input values, x and y, are whole number > or equal to 0, which are input by a single read, i.e. they cannot be read or "looked at" digit by digit. The two input values are guaranteed not to be equal to one another. for this question its is not possible to compare two numbers directly, however, comparison of two digits is allowed. you are allowed to use of all basic arithmetic operations. As well, n named sub-algorithm called Power (a,b), when invoked returns a^b, can be used.
Posted Date: 9/23/2012 3:13:21 PM | Location : United States

Related Discussions:- Comp. sci algorithms, Assignment Help, Ask Question on Comp. sci algorithms, Get Answer, Expert's Help, Comp. sci algorithms Discussions

Write discussion on Comp. sci algorithms
Your posts are moderated
Related Questions
Example: Assume the following of code: x = 4y + 3 z = z + 1 p = 1 As we have been seen, x, y, z and p are all scalar variables & the running time is constant irrespective

Complexity : How do the resource needs of a program or algorithm scale (the growth of resource requirements as a function of input). In other words, what happens with the performan

An interesting application or implementation of trees is the playing of games such as tie-tac-toe, chess, nim, kalam, chess, go etc. We can depict the sequence of possible moves

Two linked lists are having information of the same type in ascending order. Write down a module to merge them to a single linked list that is sorted merge(struct node *p, stru

Program: Creation of a linked list In the next example, wewill look to the process of addition of new nodes to the list with the function create_list(). #include #includ

The structures of files vary from operating system to operating system. In this unit, we will discuss the fundamentals of file structures with the generic file organisations. A

Compare zero-address, one-address, two-address, and three-address machines by writing programs to compute: Y = (A – B X C) / (D + E X F) for each of the four machines. The inst

In this part, students are allowed to implement the following simplifications in their table and data design. o Availability for the beauty therapists don't have to be considere

List various problem solving techniques. There are two techniques:- 1.  Top down 2.  Bottom- up

create a flowchart that displays the students average score for these quizzes