is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.
CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.
Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.
Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.
package test;
- duancwd June 09, 2015public class testcc150 {
public static int[] MinTop(int Min[] ){
int min = Min[0];
int pos =0;
int size = Min.length;
int re[]=new int[2];
for(int i = 0; i< size; i++){
if (min>Min[i]){
min = Min[i];
pos =i;
}
}
re[0]=min;
re[1]=pos;
return re;
}
public static int[] Top(int allNum[],int topnum){
int Max[] = new int[topnum] ;
int min ;
int pos;
for(int i =0 ;i< topnum; i++){
//System.out.println(allNum[i]);
Max[0]=allNum[0];
//System.out.println(Max);
Max[i] = allNum[i];
//System.out.println("this"+Max[topnum-1]);
}
min = MinTop(Max)[0];
pos = MinTop(Max)[1];
for(int i = topnum; i<allNum.length; i++){
if(min<allNum[i]){
Max[pos] = allNum[i];
min = MinTop(Max)[0];
pos = MinTop(Max)[1];
}
}
return Max;
}
public static void main(String args[]){
int[] nums2 = {1,100,3,4,5,6,7,8,9,15,11,99,32};
System.out.println(Top(nums2,3)[0]);
System.out.println(Top(nums2,3)[1]);
System.out.println(Top(nums2,3)[2]);
}
}