关键词不能为空

当前您在: 主页 > 高中公式大全 >

送别李叔同嵌入式工程师面试题_经典

作者:高考题库网
来源:https://www.bjmy2z.cn/gaokao
2021-01-21 04:03
tags:

江姐电影-什么叫安全

2021年1月21日发(作者:俞小凡)

1
、将一个字符串逆序


2
、将一个链表逆序


3
、计算一个字节里(
b yte
)里面有多少
bit
被置
1

4
、搜索给定的字节
(byte)

5
、在一个字符串中找到可能的最长的子字符串


6
、字符串转换为整数


7
、整数转换为字符串

style=

char *strconv(char *p)

{





int i,length;





char temp;





length = strlen(p);





for(i = 0;i < length/2;i++)





{









temp = *(p + i);









*(p + i) = *(p + length - 1 - i);









*(p +length - 1 - i) = temp;





}





return p;

}



int main()

{





char src[100];





char *p;





scanf(





p = strconv(src);





printf(





return 0;

}



style=
0px;
COLOR:
rgb(102,102,102);
LINE-HEIGHT:
150%
wrap=

int
cal(int
data)
//calculation the number of bit in one byte

{





int a;





int count = 0;





a = data % 100;





while (a != 0)





{









count += a % 2;









a /= 2;





}





return count;

}



int main()

{





int d,count;





scanf(





count = cal(d);





printf(





return 0;

}


style=

#include

#include



void findmax(char *p)

{





int j = 0,max = 0;





int count = 0;





char record[200];





char recordmax[200];







for(int i = 0;;i++)





{



















if((*(p + i) == ' ') || (*(p + i) == '0'))









{





















if(count > max)













{

















max = count;

















record[j] = '0';

















strcpy(recordmax,record);

























}













count = 0;













j = 0;









}









else









{













record[j] = *(p + i);













count ++;













j ++;









}









if(*(p + i) == '0')













break;





}





printf(

}



























int main()

{





char str[]=





printf(





findmax(str);





return 0;

}


style=

#include

#include



typedef struct shopping

{





char goods[100];





struct shopping *next;

}SHOP;



SHOP *buildlink()











//
创建链表


{





char goods[100];





SHOP *head,*p,*h;





p = (SHOP *)malloc(sizeof(SHOP));





head = p;





head->next = NULL;





printf(





for(int i = 0;i < 3;i++)





{









scanf(









p = (SHOP *)malloc(sizeof(SHOP));









strcpy(p->goods,goods);









p->next = NULL;









if(head->next == NULL)









{













head->next = p;













h = p;









}









else









{













h->next = p;













h = h->next;









}





}





return head;

}



void showlink(SHOP *head)

//
显示链表


{





SHOP *p;





p = head->next;





while(p != NULL)





{









printf(









p = p->next;





}





printf(

}



SHOP *revlink(SHOP *head)



//
反转链表


{





SHOP *p,*newp;





p = head->next;





head->next = NULL;





while(p != NULL)





{









newp = p;









p = p->next;









newp->next = head->next;









head->next = newp;









}





return head;

}



int delnode(SHOP *head,char *str)

{





//delete success return 1,else return 0





SHOP *q,*p = head;





while(p->next != NULL)





{









q = p;









p = p->next;

















if(!strcmp(str,p->goods))









{













q->next = p->next;













free(p);













//p = q->next;













return 1;









}





}





return 0;

}











int main()

{





SHOP *head;





SHOP *newhead;





head = buildlink();





showlink(head);


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全


江姐电影-什么叫安全



本文更新与2021-01-21 04:03,由作者提供,不代表本网站立场,转载请注明出处:https://www.bjmy2z.cn/gaokao/542266.html

嵌入式工程师面试题_经典的相关文章