Answer:
please find the attachment of the correct code:
Output:
Bob : 1234
sue : 5678
pat : 2468
please enter a name to replace with pat:
Chris
Bob : 1234
sue : 5678
Chris : 2468
Explanation:
In this code, when we create the class object, that is "stu1, stu2, and stu3" and call the parameterized constructor bypassing the "string and integer" value and print the object value you forget to call the "tostring" method because it is the only method which returns both "string and integer" value.
Binary (base 2) is much easier to encode on a hard drive as it only has two states, whereas letters, numbers and symbols can be one of hundreds.
Explanation:
As a result, it is important not to overlook any of the sources of information that indicate what the form of the model should be. Answer Not ...
Knowing Function Types Helps: Another helpful ingredient in model selection
I’m sorry this is unclear . What exactly do you need .
Answer:
#include<stdio.h>
int GetLargest()
{
int a[100],n,largest;
printf("Enter number of elements\n");
scanf("%d",&n);
printf("Enter elements\n");
for(int i=0;i<n;i++)
scanf("%d",&a[i]);
i=0;
largest=a[i];
while(i<n)
{
i++
if(a[i]>largest)
largets=a[i];
}
return largest;
}
void main(){
int largest;
largest=GetLargest();
printf("Largest Number is %d",largest);
}
Explanation:
Here we define one function "GetLargest". This function reads n number of elements and finds the largest number among the n elements. Here we took one array and assumed first element is the largest element. if any element of the array is greater that that element we make that as larger and continues.at the end we are getting largest element in the n numbers and returning that to the main.