This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: d ____ a special method that is used to set up a newly created object. f ____ data is declared within a method and it can be used only in that method. 2). Convert the following algebraic expressions into valid C# code. a. C B A (A+B)/C b. 2 2 B A Math.Sqrt(Math.Pow(A,2)+Math.Pow(B,2)) c. Y X C B A (A+B*C)/(X-Y) d. | A B | Math.Abs(A-B) e. A B Math.Pow(A,B) Name________________________ CSE182 2 3) What will be the value of answer after executing each of the following? double answer; a. answer = Math.Floor(43.2); 43 b. answer = Math.Max(53.43, 23.3); 53.43 c. answer = Math.Abs(-65.3); 65.3 d. answer = Math.Sqrt(4); 2 e. answer = Math.Pow(2,3); 8 f. answer = Math.Ceiling(76.2); 77 g. answer = Math.Min(23.43, 43.2); 23.43 h. answer = Math.Round(43.242789678, 3); 43.243...
View Full Document
This note was uploaded on 02/11/2010 for the course CSE CSE182 taught by Professor Feng during the Spring '10 term at ASU.
- Spring '10