Posts by Ken • 146 points
8 posts
-
0
votes2
answers407
viewsA: List chained insertion at end
Keep in mind that you should store the reference to the first node in the list. With each insertion, you must search for the last node and then make the next node to be the new one. Also, your list…
-
1
votes1
answer319
viewsA: How to fill an entire array with malloc(sizeof(int)) with some value
At the time you allocate this vector using malloc, also store its size in the structure... And make a loop for to fill as you wish. argumentos->posicCertas = (int*)malloc(sizeof(int)*n_pos);…
-
1
votes1
answer4344
viewsA: Git "Please Tell me who you are"
I need to post the same e-mail from github ? No. However, for safety, we can make the Github rejects commits that display private configured emails. Whenever I open the app I need to add this…
-
0
votes1
answer72
viewsA: Difficulty implementing chess board
First I think you’re drawing the board starting with the columns, not the lines. But considering the board is square, it wouldn’t make a difference... for(i = 0; i < larg; i++){ for(k = 0; k <…
-
0
votes1
answer272
viewsA: Running time in C
I do not think it is necessary to do the CLOCKS_PER_SEC/1000 division. Note that you have the length of the piece of code that interests you in diff. To get the time, just make the next rule of 3 1s…
-
2
votes1
answer177
viewsA: select one of the words contained in the list
You are with a useless variable i. for palavra in lista: if palavra == buscada: print('a palavra buscada foi encontrada na lista') Another way would be: if buscada in lista: print('palavra…
-
1
votes2
answers228
views -
2
votes3
answers83
viewsA: Raspberry for monitoring system
In general, it is possible. It just depends on how you will describe and identify what is something out of the ordinary... But things like identifying that there are people is very simple. Search on…