#includestdiohint main int a3temp; forint i=0;i3;i++ scanfd&ai; forint i=0;i2;i++ forint j=i;j3;j++ ifajaj+1 temp=aj; aj=aj+1;
The code takes three integer inputs from the user, sorts them in ascending order using bubble sort algorithm, and then outputs them in the format a->b->c.
Example input: 5 2 7
Output: 2->5->7
原文地址: https://www.cveoy.top/t/topic/bcf8 著作权归作者所有。请勿转载和采集!