Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Problem:

Question- Describe an algorithm that uses only assignment statements that replaces (x, y, z) with (y, z, x). What is the minimum number of assignment statements needed?

By solutions, the answer is like that.
a:=x, b:=y, c:=z, x:=y, y:=z, z:=x, y:=a, z:=b, x:=c
Then it needs minimum nine assignment statement.
(It's problem of 12E of Chapter 3.1, DIscrete Mathematics and its applications 7th edition).

But I don't understand. It seems that it's just four. Because, I think that a:=x, x:=y, y:=z, z:=a can be a solution. Especially I don't understand last three statements. Why am I need them? If it is wrong, what's the wrong point?

Please Explain don't just write the answer.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M91174986

Have any Question?


Related Questions in Computer Engineering

In sql developerd1 create the following three user-defined

IN SQL DEVELOPER D1. Create the following three user-defined roles that are shown in the table below and assign them the specified permissions for the OE.CUSTOMERS table. Role Select Insert Update Delete account_managers ...

Show your steps of how you found your calculations please

Show your steps of how you found your calculations. Please type reponse. Suppose the daytime processing load consists of 60% CPU activity and 40% disk activity. Your customers are complaining that the system is slow. Aft ...

Give examples of how dominos has adapted its global

Give examples of how Domino's has adapted its global marketing mix to meet the needs of local consumers. Are you their customer? If so, why?

Can someone help me with thiswrite your own class called

can someone help me with this Write your own class called WeatherStats to manage the ordered collection of high temperatures. Have two constructors, one for a default maximum size collection of 10, and the second for a u ...

Write a java console application that calculates and

Write a java console application that calculates and displays the bank interest for N bank accounts. N should be declared as a constant and it should be equal to the largest digit of your student ID number (e.g. if your ...

The requirements analysis phase is an essential part of a

The requirements analysis phase is an essential part of a system development methodology. According to the FAST methodology, which stake-holders typically participate in this phase? What is the primary focus of requireme ...

What are the minimum and maximum values in decimal if an

What are the minimum and maximum values (in decimal) if an 8-bit binary number is given unsigned and two's complement formats?

Question overview of information security and risk

Question: Overview of Information Security and Risk Management (Due Oct 24) Does your company (or school) have a current disaster recovery plan? What are some of the activities involved in it? Do you feel confident that ...

Write a program that populates an array named weekday from

Write a program that populates an array named weekday from the string SunMonTueWedThuFriSat, and then prints each day in uppercase. PERL Language.

Please help with anbspfunctionnbspcodesymbol to convert

Please help with a function  codeSymbol , to convert each mark to a symbol (A, B, C, D, E, F) and a code (7,6,5,4,3,2,1) according to the table below. And call it in the main function. Use the table below to determine th ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As