how can i make a function that accepts as input a vector of integers, which will return the largest and the second largest component of the vector for the first i think that is max1=max(max(C)) any idea for max2?
Sorry, felix, that I've solved your homework. Now it gets hard to submit it without cheating. Remember, that your teacher/assistent knwos this forum also, so it is strongly recommended to mention all sources.