static void Main() { Console.WriteLine(FileOperations.GetFileExtension("example")); Console.WriteLine(FileOperations.GetFileExtension("example.pdf")); Console.WriteLine(FileOperations.GetFileExtension("example.new.pdf")); Console.WriteLine(FileOperations.GetFileNameWithoutExtension("example")); Console.WriteLine(FileOperations.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileOperations.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine("Distance in the 2D space = {0:f2}", GeometryOperations.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine("Distance in the 3D space = {0:f2}", GeometryOperations.CalcDistance3D(5, 2, -1, 3, -6, 4)); Figure3D figure3D = new Figure3D(); figure3D.Width = 3; figure3D.Height = 4; figure3D.Depth = 5; Console.WriteLine("Volume = {0:f2}", figure3D.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", figure3D.CalcDiagonalXYZ()); Console.WriteLine("Diagonal XY = {0:f2}", figure3D.CalcDiagonalXY()); Console.WriteLine("Diagonal XZ = {0:f2}", figure3D.CalcDiagonalXZ()); Console.WriteLine("Diagonal YZ = {0:f2}", figure3D.CalcDiagonalYZ()); }
public static void Main() { Console.WriteLine(FileNameManager.GetFileExtension("example")); Console.WriteLine(FileNameManager.GetFileExtension("example.pdf")); Console.WriteLine(FileNameManager.GetFileExtension("example.new.pdf")); Console.WriteLine(FileNameManager.GetFileNameWithoutExtension("example")); Console.WriteLine(FileNameManager.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileNameManager.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine( "Distance in the 2D space = {0:f2}", DistanceCalculator.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine( "Distance in the 3D space = {0:f2}", DistanceCalculator.CalcDistance3D(5, 2, -1, 3, -6, 4)); double width = 3; double height = 4; double depth = 5; var figure3D = new Figure3D(width, height, depth); Console.WriteLine("Volume = {0:f2}", figure3D.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", figure3D.CalcDiagonalXYZ()); Console.WriteLine("Diagonal XY = {0:f2}", figure3D.CalcDiagonalXY()); Console.WriteLine("Diagonal XZ = {0:f2}", figure3D.CalcDiagonalXZ()); Console.WriteLine("Diagonal YZ = {0:f2}", figure3D.CalcDiagonalYZ()); }
private static void Main() { Console.WriteLine(FileNameUtils.GetFileExtension("example")); Console.WriteLine(FileNameUtils.GetFileExtension("example.pdf")); Console.WriteLine(FileNameUtils.GetFileExtension("example.new.pdf")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine("Distance in the 2D space = {0:f2}", CalcDistanceUtils.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine("Distance in the 3D space = {0:f2}", CalcDistanceUtils.CalcDistance3D(5, 2, -1, 3, -6, 4)); Figure3D testFigure3D = new Figure3D(3, 4, 5); Console.WriteLine("Volume = {0:f2}", testFigure3D.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", testFigure3D.CalcDiagonalXyz()); Console.WriteLine("Diagonal XY = {0:f2}", testFigure3D.CalcDiagonalXy()); Console.WriteLine("Diagonal XZ = {0:f2}", testFigure3D.CalcDiagonalXz()); Console.WriteLine("Diagonal YZ = {0:f2}", testFigure3D.CalcDiagonalYz()); }
private static void Main() { Console.WriteLine(FileNameSplitter.GetFileExtension("example")); Console.WriteLine(FileNameSplitter.GetFileExtension("example.pdf")); Console.WriteLine(FileNameSplitter.GetFileExtension("example.new.pdf")); Console.WriteLine(FileNameSplitter.GetFileNameWithoutExtension("example")); Console.WriteLine(FileNameSplitter.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileNameSplitter.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine("Distance in the 2D space = {0:f2}", DimensionDistanceCalculater.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine("Distance in the 3D space = {0:f2}", DimensionDistanceCalculater.CalcDistance3D(5, 2, -1, 3, -6, 4)); var figure3D = new Figure3D(4, 3, 5); Console.WriteLine("Volume = {0:f2}", figure3D.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", figure3D.CalcDiagonalXYZ()); Console.WriteLine("Diagonal XY = {0:f2}", figure3D.CalcDiagonalXY()); Console.WriteLine("Diagonal XZ = {0:f2}", figure3D.CalcDiagonalXZ()); Console.WriteLine("Diagonal YZ = {0:f2}", figure3D.CalcDiagonalYZ()); }
private static void Main() { Console.WriteLine(FileNameUtils.GetFileExtension("example")); Console.WriteLine(FileNameUtils.GetFileExtension("example.pdf")); Console.WriteLine(FileNameUtils.GetFileExtension("example.new.pdf")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileNameUtils.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine("Distance in the 2D space = {0:f2}", CalcDistanceUtils.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine("Distance in the 3D space = {0:f2}", CalcDistanceUtils.CalcDistance3D(5, 2, -1, 3, -6, 4)); Figure3D testFigure3D = new Figure3D(3, 4, 5); Console.WriteLine("Volume = {0:f2}", testFigure3D.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", testFigure3D.CalcDiagonalXyz()); Console.WriteLine("Diagonal XY = {0:f2}", testFigure3D.CalcDiagonalXy()); Console.WriteLine("Diagonal XZ = {0:f2}", testFigure3D.CalcDiagonalXz()); Console.WriteLine("Diagonal YZ = {0:f2}", testFigure3D.CalcDiagonalYz()); }
static void Main() { Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example")[1]); Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example.pdf")[1]); Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example.new.pdf")[1]); Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example")[0]); Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example.pdf")[0]); Console.WriteLine(UtilsFile.SplitFileNameAndExtension("example.new.pdf")[0]); Console.WriteLine("Distance in the 2D space = {0:f2}", UtilsDistance.CalculateDistance2D(1, -2, 3, 4)); Console.WriteLine("Distance in the 3D space = {0:f2}", UtilsDistance.CalculateDistance3D(5, 2, -1, 3, -6, 4)); Figure3D figure = new Figure3D(3, 4, 5); Console.WriteLine("Volume = {0:f2}", figure.CalcVolume()); Console.WriteLine("Diagonal XYZ = {0:f2}", figure.CalcDiagonalXYZ()); Console.WriteLine("Diagonal XY = {0:f2}", figure.CalcDiagonalXY()); Console.WriteLine("Diagonal XZ = {0:f2}", figure.CalcDiagonalXZ()); Console.WriteLine("Diagonal YZ = {0:f2}", figure.CalcDiagonalYZ()); }
internal static void Main() { Console.WriteLine(FileUtils.GetFileExtension("example")); Console.WriteLine(FileUtils.GetFileExtension("example.pdf")); Console.WriteLine(FileUtils.GetFileExtension("example.new.pdf")); Console.WriteLine(FileUtils.GetFileNameWithoutExtension("example")); Console.WriteLine(FileUtils.GetFileNameWithoutExtension("example.pdf")); Console.WriteLine(FileUtils.GetFileNameWithoutExtension("example.new.pdf")); Console.WriteLine( "Distance in the 2D space = {0:f2}", DistanceCalculator.CalcDistance2D(1, -2, 3, 4)); Console.WriteLine( "Distance in the 3D space = {0:f2}", DistanceCalculator.CalcDistance3D(5, 2, -1, 3, -6, 4)); Figure3D figure = new Figure3D(3, 4, 5); Console.WriteLine("Figure3D Volume = {0:f2}", figure.CalcVolume()); Console.WriteLine("Figure3D Diagonal XYZ = {0:f2}", figure.CalcDiagonalXYZ()); Console.WriteLine("Figure3D Diagonal XY = {0:f2}", figure.CalcDiagonalXY()); Console.WriteLine("Figure3D Diagonal XZ = {0:f2}", figure.CalcDiagonalXZ()); Console.WriteLine("Figure3D Diagonal YZ = {0:f2}", figure.CalcDiagonalYZ()); }