Final commit :)

master
gnomerd 5 years ago
parent 93f2aa7a12
commit f142c8e346
  1. BIN
      2019/1/bin/Debug/netcoreapp2.2/1.dll
  2. BIN
      2019/1/bin/Debug/netcoreapp2.2/1.pdb
  3. BIN
      2019/1/obj/Debug/netcoreapp2.2/1.dll
  4. BIN
      2019/1/obj/Debug/netcoreapp2.2/1.pdb
  5. 0
      2019/Day1/1.csproj
  6. 3
      2019/Day1/Program.cs
  7. 0
      2019/Day1/bin/Debug/netcoreapp2.2/1.deps.json
  8. BIN
      2019/Day1/bin/Debug/netcoreapp2.2/1.dll
  9. BIN
      2019/Day1/bin/Debug/netcoreapp2.2/1.pdb
  10. 0
      2019/Day1/bin/Debug/netcoreapp2.2/1.runtimeconfig.dev.json
  11. 0
      2019/Day1/bin/Debug/netcoreapp2.2/1.runtimeconfig.json
  12. 0
      2019/Day1/input.txt
  13. 0
      2019/Day1/obj/1.csproj.nuget.cache
  14. 0
      2019/Day1/obj/1.csproj.nuget.dgspec.json
  15. 0
      2019/Day1/obj/1.csproj.nuget.g.props
  16. 0
      2019/Day1/obj/1.csproj.nuget.g.targets
  17. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.AssemblyInfo.cs
  18. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.AssemblyInfoInputs.cache
  19. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.assets.cache
  20. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.csproj.CoreCompileInputs.cache
  21. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.csproj.FileListAbsolute.txt
  22. 0
      2019/Day1/obj/Debug/netcoreapp2.2/1.csprojAssemblyReference.cache
  23. BIN
      2019/Day1/obj/Debug/netcoreapp2.2/1.dll
  24. BIN
      2019/Day1/obj/Debug/netcoreapp2.2/1.pdb
  25. 0
      2019/Day1/obj/project.assets.json

@ -10,12 +10,15 @@ namespace _1
string[] inputs = input.Split( Environment.NewLine, StringSplitOptions.None );
int[] output = new int[100];
double input_;
int sum = 0;
for ( int i = 0; i < inputs.Length; i++ ) {
Console.WriteLine( inputs[i] );
input_ = Convert.ToDouble(inputs[i]);
output[i] = (int)Math.Floor( input_/3 ) - 2;
Console.WriteLine(output[i]);
sum += output[i];
}
Console.WriteLine("Sum: " + sum.ToString() );
}
}
}
Loading…
Cancel
Save