#include char s[2000]; FILE *f; int v[200][1100]; int n,k,t,x,y,pos,prof,mincosto,sce=1; int find(int x) { int i,j,count,group; j=0; count = group = 1; for(i=1;;i++) { j++; if (j == n) { j =1; group++; count = 1; } if (count == group) count++; if (i == x) return count; count++; } } void profo(int costo,int pos) {int x; prof++; for(x=pos*(n-1)-(n-2);x<=pos*(n-1);x++) if(v[x][prof]) {costo+=v[x][prof]; if(prof==k) {if(find(x)==n && costo