📅  最后修改于: 2022-03-11 15:04:42.335000             🧑  作者: Mango
#include
void science_writing(float *number){
int result=0;
if(*number>1){
while (*number>1){
result++;
*number/=10;
}
printf("%d",result);
printf("the science writing of this number i;$s :%f × 10^%d",*number,result);
}
else if(*number<1){
while(*number<1){
result++;
*number*=10;
}
printf("the science writing of this number i;$s :%f × 10^-%d",*number*0.1,result-1);
}
}
int main()
{
float momne;
int result=0;
printf("enter the number :");
scanf("%f",&momne);
science_writing(&momne);
return 0;
}