Answered step by step
Verified Expert Solution
Question
1 Approved Answer
DEBUGING IN C LANGUAGE Program 3: int element(int arr[], int num) { in i, ele; ele = arr[0]; for (i = 1; i < num;
DEBUGING IN C LANGUAGE
Program 3:
int element(int arr[], int num)
{
in i, ele;
ele = arr[0];
for (i = 1; i < num; i++)
if (arr[i] > ele)
ele = arr[i];
return ele;
}
main()
{
arr[] = {1, 24, 145, 20, 8, -101, 300};
int n = sizeof(arr)/sizeof(arr[0]);
printf("element of array is %d", element(arr[], n));
}
- 24
- 145
- -101
- 300
Program 4:
main()
{
int m,n;
for(i 0; i << 5; i++)
{
printf("\t\t\t\t");
for(j 0; j << 5; j+++)
printf("*");
printf("/n");
}
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