0

I need help to highlight peak point in the graph without using library in C

#include<stdio.h> #include<conio.h> main() { int i,j=0; int a[50]={10,7,12,2,4,7,2,4,1,2}; int x=1,y=25; char toggle='U',c; clrscr(); cprintf("welcome"); { if(toggle=='U') { for(i=1;i<=a[j];i++) { gotoxy(x++,y--); cprintf("/"); } toggle='D'; } else { c='\\'; for(i=1;i<=a[j];i++) { gotoxy(x++,y++); cprintf("\\"); } toggle='U'; } j++; getch(); if(j>=9) break; } }

9th Jan 2021, 12:49 PM
Magesh
2 Respostas
+ 3
There are a lot of non-standard functions in use, there in your program
9th Jan 2021, 12:59 PM
Arsenic
Arsenic - avatar
0
I'm getting exact output from this code based on the inputs in the array A ... I just need to highlight the peak point...In this case the peak point is 12...
9th Jan 2021, 1:03 PM
Magesh