The original photo of the beans is this:
Decreasetheresolutionofthephoto,Ialreadyappliedafiltertobeingrayscaleandincreasedthecontrasttothemaximumtobecomeblackandwhite.ThenIexaminedthecolorofeachpixelandmountedanarrayarray.IfIloopoverthisarra...
I'm trying to understand how pointers work for an array. For this, I elaborated the small program below. I made some mistake because, in the line indicated, segmentation fault is occurring.
What is the correct way to pass the pointer pointi...
I have a job for my course, and it is necessary to make a program similar to the megasena game. It's almost ready, but I'm finding a little problem and need help.
Data of the work: maximum of 10 players can bet, each one can bet from 6 up to 15...
The idea is to create an array of integers with the amount of rows and columns defined by the user. Then an existing value in the array must be entered and the program should return the values immediately to the left, right, above and below the...
I'm studying computational efficiency in R, generating matrices through different methods.
First, I generate an array of vector form and calculate the variances for its columns:
matriz <- matrix(rep(NA, 1000*200), nrow = 1000, ncol=200)...
I am doing the following operation with an array in the R:
> m <- matrix(1:9, ncol = 3, nrow = 3)
> m
[,1] [,2] [,3]
[1,] 1 4 7
[2,] 2 5 8
[3,] 3 6 9
> m2 <- m
> for(i in 1:nrow(m)){
+ for(j...