Advertisement
Guest User

Untitled

a guest
Nov 23rd, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. static void Main(string[] args)
  2. {
  3. List<float> i0 = new List<float>() { 30f, 30f, 30f, 10f };
  4. int packCount = i0.Count;
  5. string str = "Input: ";
  6. for (int i = 0; i < packCount; ++i)
  7. str += i0[i] + " ; ";
  8. str.Remove(str.Length - 3, 3);
  9. Console.WriteLine(str);
  10. int[] s0 = Backtracking.Compute(i0, 100f);
  11. string r0 = "Solution: ";
  12. int indexesCount = s0.Length;
  13. for (int i = 0; i < indexesCount; ++i)
  14. r0 += i0[s0[i]] + " ; ";
  15. r0.Remove(r0.Length - 3, 3);
  16. Console.WriteLine(s0);
  17. Console.ReadKey();
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement