Question
1_ What is the output? private void btnMethods_Click(object sender, EventArgs e) { int arg1 = 2; double val = ValReturnMethod(arg1, 2.00); MessageBox.Show(val.ToString()); } private void
1_ What is the output?
private void btnMethods_Click(object sender, EventArgs e)
{
int arg1 = 2;
double val = ValReturnMethod(arg1, 2.00);
MessageBox.Show(val.ToString());
}
private void ValReturnMethod(int val, double val2)
{
return val1 * val2 *25.50;
}
_____________________________
2_ What is the output?
private void btnMethods_Click(object sender, EventArgs e)
{
int arg1 = 4;
double val = ValReturnMethod(ref arg1);
MessageBox.Show(arg1.ToString());
}
private double ValReturnMethod(ref int val1)
{
return val1 *25.50;
}
______________________________
3_ What is the output?
private void btnMethods_Click(object sender, EventArgs e)
{
int arg1 = 4;
double arg2 = 10.50;
MessageBox.Show(ValReturnMethod(arg1,arg2).ToString());
}
private double ValReturnMthod (int val1,double val2)
{
return val1 * 25.50;
}
___________________________
This is not C++ it is Visual C#
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started