private bool GetDeviceInfo_bool(DeviceInfo paramName) { uint ret = default(uint); CheckError(CL.GetDeviceInfo <uint>(DeviceId, paramName, IntSizePtr, ref ret, (IntPtr *)NullPtr)); return((Bool)ret == Bool.True); }
public bool CopyBuild(DirectoryReference InstallPath) { CommandUtils.LogInformation("Installing shared cooked build from manifest: {0} to {1}", Manifest.FullName, InstallPath.FullName); DirectoryReference PlatformInstallPath = DirectoryReference.Combine(InstallPath, Platform.ToString()); FileReference PreviousManifest = FileReference.Combine(PlatformInstallPath, ".build", "Current.manifest"); FileReference BPTI = FileReference.Combine(CommandUtils.RootDirectory, "Engine", "Binaries", "Win64", "NotForLicensees", "BuildPatchToolInstaller.exe"); if (!FileReference.Exists(BPTI)) { CommandUtils.LogInformation("Could not locate BuildPatchToolInstaller.exe"); return false; } bool PreviousManifestExists = FileReference.Exists(PreviousManifest); if (!PreviousManifestExists && DirectoryReference.Exists(PlatformInstallPath)) { DirectoryReference.Delete(PlatformInstallPath, true); } IProcessResult Result = CommandUtils.Run(BPTI.FullName, string.Format("-Manifest={0} -OutputDir={1} -stdout -GenericConsoleOutput", Manifest.FullName, PlatformInstallPath.FullName), null, CommandUtils.ERunOptions.Default); if (Result.ExitCode != 0) { CommandUtils.LogWarning("Failed to install manifest {0} to {1}", Manifest.FullName, PlatformInstallPath.FullName); return false; } FileReference SyncedBuildFile = new FileReference(CommandUtils.CombinePaths(PlatformInstallPath.FullName, SyncedBuildFileName)); FileReference.WriteAllLines(SyncedBuildFile, new string[] { CL.ToString(), Manifest.FullName }); return true; }
private uint GetDeviceInfo_uint(DeviceInfo paramName) { uint ret = default(uint); CheckError(CL.GetDeviceInfo <uint>(DeviceId, paramName, IntSizePtr, ref ret, (IntPtr *)NullPtr)); return(ret); }
private ulong GetDeviceInfo_ulong(DeviceInfo paramName) { ulong ret = default(ulong); CheckError(CL.GetDeviceInfo <ulong>(DeviceId, paramName, LongSizePtr, ref ret, (IntPtr *)NullPtr)); return(ret); }
private void ExitWorld(MmoActor actor) { //reset target when exiting world actor.GetComponent <PlayerTarget>().Clear(); actor.GetComponent <PlayerLoaderObject>().Save(true); var worldExited = new WorldExited { WorldName = ((MmoWorld)actor.World).Name }; actor.nebulaObject.SetInvisibility(false); actor.Dispose(); // set initial handler ((MmoPeer)actor.Peer).SetCurrentOperationHandler((MmoPeer)actor.Peer); var eventData = new EventData((byte)EventCode.WorldExited, worldExited); actor.UpdateCharacterOnMaster(); // use item channel to ensure that this event arrives in correct order with move/subscribe events actor.Peer.SendEvent(eventData, new SendParameters { ChannelId = Settings.ItemEventChannel }); CL.Out(LogFilter.PLAYER, "ExitWorld() Player {0} from world {1}".f(actor.name, ((MmoWorld)actor.World).Name)); }
/// <summary> /// Задание 3 /// </summary> private static void Task3() { CL.BeginApp("Калькулятор"); CL.ConsolePause(); Menu(); }
public static T GetDeviceInfo <T>(IntPtr deviceId, DeviceInfo paramName) where T : struct { T ret = default(T); CheckError(CL.GetDeviceInfo <T>(deviceId, paramName, new IntPtr(sizeof(IntPtr)), ref ret, (IntPtr *)NullPtr)); return(ret); }
/// <summary> /// Задание 1 /// </summary> private static void Task1() { CL.BeginApp("Пузырьковая сортировка"); System.Console.WriteLine("Количество элементов массива:"); int amount = Utils.IsInt(); int[] array = new int[amount]; int[] bublArray = new int[amount]; int[] advBublArray = new int[amount]; Utils.RandArray(array); for (int i = 0; i < array.Length; i++) { bublArray[i] = array[i]; advBublArray[i] = array[i]; } //CL.PrintArr(array); System.Console.WriteLine("Сортировка пузырьком"); Sort.BubbleSort(bublArray); //CL.PrintArr(bublArray); System.Console.WriteLine("Сортировка улучшеным пузырьком"); Sort.AdvBubbleSort(advBublArray); //CL.PrintArr(advBublArray); CL.ConsolePause(); Menu(); }
public override void Execute() { CL.StartStep(this); //Stay for a 30 secs to get RB filled up. int Wait_Period = 30; CL.Platform.IEX.Wait(Wait_Period); //rewind res = CL.EA.PVR.SetTrickModeSpeed("RB", -2, false, false); if (!res.CommandSucceeded) { CL.FailStep(res, "Failed to activate rewind from Review Buffer at x(-2) Speed"); } //Rewind shall continue for 30 secs Wait_Period = 5; CL.Platform.IEX.Wait(Wait_Period); // Play the event from Review Buffer res = CL.EA.PVR.SetTrickModeSpeed("RB", 1, false); if (!res.CommandSucceeded) { CL.FailStep(res, "Failed to Set the Trick mode to Play "); } CL.PassStep(); }
/// <summary> /// Задание 4 /// </summary> private static void Task4() { CL.BeginApp("Копирование односвязного списка"); CL.ConsolePause(); Menu(); }
public string get_client_list()//Clients holen { string clientlist = ""; int i = 1; ObservableCollection <SmartHomeClient> akt_liste = (ObservableCollection <SmartHomeClient>)HauptForm.get_clientlist();//Client List aus der Hauptform holen if (akt_liste != null) { foreach (SmartHomeClient CL in akt_liste) //Loop durch die einzelnen Clients { if (i == akt_liste.Count) //check ob i die gleiche Größe hat, wie die Anzahl der Clients in der Liste { clientlist = clientlist + CL.GetId().ToString() + "-" + CL.ebene.ToString() + "-" + ((IPEndPoint)CL._TcpClient.Client.RemoteEndPoint).Address.ToString(); //letzten Client in den String schreiben } else { clientlist = clientlist + CL.GetId().ToString() + "-" + CL.ebene.ToString() + "-" + ((IPEndPoint)CL._TcpClient.Client.RemoteEndPoint).Address.ToString() + ";"; //Clients mit Semikolon getrennt in den String schreiben } i++; //i erhöhen } } else { clientlist = "leer"; // wenn keine Clients in der Datenbank sind oder ein Problem mit der Abfrage vorhanden ist, wird als Liste "leer" zurückgegeben } return(clientlist); //rückgabe der Clients }
/// <summary> /// Задание 2 /// </summary> private static void Task2() { CL.BeginApp("Переписать программу, реализующую двоичное дерево поиска"); BinaryTree <int> integerTree = new BinaryTree <int>(); Random rand = new Random(); for (int i = 0; i < 20; i++) { int value = rand.Next(100); integerTree.Add(value); } Console.WriteLine("Number of nodes is {0}", integerTree.Count); Console.WriteLine("Max value is {0}", integerTree.MaxValue); Console.WriteLine("Min value is {0}", integerTree.MinValue); Console.WriteLine("Pre-order traversal:"); Console.WriteLine(string.Join(" ", integerTree.Preorder())); Console.WriteLine("In-order traversal:"); Console.WriteLine(string.Join(" ", integerTree.Inorder())); Console.WriteLine("Post-order traversal:"); Console.WriteLine(string.Join(" ", integerTree.Postorder())); Console.WriteLine("Level-order traversal:"); Console.WriteLine(string.Join(" ", integerTree.Levelorder())); Console.WriteLine("Default traversal (inorder):"); foreach (int n in integerTree) { Console.Write("{0} ", n); } Console.WriteLine(); CL.ConsolePause(); Menu(); }
public static double Func() { VT vt = new VT(1); vt.a1 = -2.0386427882503781E-07; vt.a4 = 0.5F; CL cl = new CL(); vtstatic.a1 = -2.0386427882503781E-07; vtstatic.a4 = 0.5F; cl.arr3d[4, 0, 3] = 1.1920928955078125E-07; float asgop0 = vtstatic.a4; asgop0 -= (0.484375F); if (((vtstatic.a4 * clstatic.a5)) <= (vtstatic.a4)) { return Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1)))); } else { if ((cl.arr3d[4, 0, 3]) < ((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1))))) { double if0_1retval = Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1)))); return if0_1retval; } } return Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1)))); }
/// <summary> /// Задание 3 /// </summary> private static void Task3() { CL.BeginApp("Разработать базу данных студентов"); CL.ConsolePause(); Menu(); }
/// <summary> /// Задание 2 /// </summary> private static void Task2() { CL.BeginApp("Проверка на выделение памяти"); CL.ConsolePause(); Menu(); }
public static IntPtr GetDevice(IntPtr cxMainContext, uint deviceIndex) { // get the list of GPU devices associated with context IntPtr[] devices; CL.GetContextInfo(cxMainContext, CLContext.Devices, out devices); return(devices[deviceIndex]); }
/// <summary> /// Задание 6 /// </summary> private static void Task6() { CL.BeginApp("Реализовать очередь"); CL.ConsolePause(); Menu(); }
public IntPtr CreateAndCompileProgram(string source) { ErrorCode error; IntPtr programId; programId = CL.CreateProgramWithSource(ContextId, 1, new string[] { source }, null, &error); if (error != ErrorCode.Success) { throw new System.InvalidOperationException(String.Format("Error calling CreateProgramWithSource: {0}", error)); } error = (ErrorCode)CL.BuildProgram(programId, 0, (IntPtr[])null, null, IntPtr.Zero, IntPtr.Zero); if (error != ErrorCode.Success) { uint parmSize; CL.GetProgramBuildInfo(programId, DeviceId, ProgramBuildInfo.ProgramBuildLog, IntPtr.Zero, IntPtr.Zero, (IntPtr *)&parmSize); byte[] value = new byte[parmSize]; fixed(byte *valuePtr = value) { error = (ErrorCode)CL.GetProgramBuildInfo(programId, DeviceId, ProgramBuildInfo.ProgramBuildLog, new IntPtr(&parmSize), new IntPtr(valuePtr), (IntPtr *)IntPtr.Zero.ToPointer()); } if (error != ErrorCode.Success) { throw new System.InvalidOperationException(String.Format("Error calling GetProgramBuildInfo: {0}", error)); } throw new System.InvalidOperationException(Encoding.ASCII.GetString(value).Trim('\0')); } return(programId); }
public static void InitCL() { int ciErrNum = 0; cxMainContext = OclCommon.CreateContextFromType(deviceType, ref ciErrNum); if (ciErrNum != 0) { System.Windows.Forms.MessageBox.Show("OpenCL CreateContextFromType failed, error " + ciErrNum); return; } int numDev = OclUtils.GetNumDevices(cxMainContext); if (numDev == 0) { System.Windows.Forms.MessageBox.Show("No OpenCL devices found."); return; } device = OclUtils.GetDevice(cxMainContext, 0); OclUtils.PrintDeviceInfo(device); commandQueue = CL.CreateCommandQueue(cxMainContext, device, CLCommandQueueProperties.None, out ciErrNum); if (ciErrNum != 0) { System.Windows.Forms.MessageBox.Show("OpenCL CreateCommandQueue failed, error " + ciErrNum); } }
public static double Func() { VT vt = new VT(1); vt.a1 = -2.0386427882503781E-07; vt.a4 = 0.5F; CL cl = new CL(); vtstatic.a1 = -2.0386427882503781E-07; vtstatic.a4 = 0.5F; cl.arr3d[4, 0, 3] = 1.1920928955078125E-07; float asgop0 = vtstatic.a4; asgop0 -= (0.484375F); if (((vtstatic.a4 * clstatic.a5)) <= (vtstatic.a4)) { return(Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1))))); } else { if ((cl.arr3d[4, 0, 3]) < ((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1))))) { double if0_1retval = Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1)))); return(if0_1retval); } } return(Convert.ToDouble((((vtstatic.a4 * clstatic.a5) + (asgop0 - (0.25F - 0.235290527F))) / (cl.arr3d[4, 0, 3] - (vt.a1))))); }
public async Task Setup() { _moduleManager = new ScreenCaptureModuleManager(new IScreenCaptureModule[] { new DxgiScreenCaptureModule(), new DxgiScreenCaptureBitmapModule(), new DxgiScreenCaptureOclModule() }); _manager = new ScreenCaptureManager(_moduleManager); _screen = _manager.GetScreens().FirstOrDefault(); _api = CL.GetApi(); using var capture = await _manager.Capture(_screen); if (capture is not DxgiScreenCapture dxgiCapture) { throw new Exception("Dxgi screen capture is required."); } (_platformId, _deviceId) = FindFirstGpuPlatform(_api); if (_platformId == default) { throw new Exception("No GPU device found."); } _contextId = CreateContext(_api, _platformId, _deviceId); var queueId = _api.CreateCommandQueue(_contextId, _deviceId, default, out var err);
private static int f(short a1, ushort a2, int a3, uint a4, long a5, ulong a6, byte a7, sbyte a8, Decimal a9, int[] a10, VT a11, CL a12, int a13, int a14, int a15, int a16, int a17, int a18, int a19, int a20, int a21, int a22, int a23, int a24, int a25) { Console.WriteLine(a1); Console.WriteLine(a2); Console.WriteLine(a3); Console.WriteLine(a4); Console.WriteLine(a5); Console.WriteLine(a6); Console.WriteLine(a7); Console.WriteLine(a8); Console.WriteLine(a9); Console.WriteLine(a10[0]); Console.WriteLine(a11.m); Console.WriteLine(a12.n); Console.WriteLine(a13); Console.WriteLine(a14); Console.WriteLine(a15); Console.WriteLine(a16); Console.WriteLine(a17); Console.WriteLine(a18); Console.WriteLine(a19); Console.WriteLine(a20); Console.WriteLine(a21); Console.WriteLine(a22); Console.WriteLine(a23); Console.WriteLine(a24); Console.WriteLine(a25); int sum = f1(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19, a20, a21, a22, a23, a24, a25); return sum; }
private void PushUsingCL(CancellationToken token) { var packageFilename = Directory .GetFiles(PackageDirectory, $"{PackageId}.*.nupkg") .FirstOrDefault(); CL.Push(packageFilename, token); }
public static void Quit() { CL.Shutdown(); if (!Globals.appletMode) { Environment.Exit(0); } }
protected virtual void Dispose(bool disposing) { if (!this.disposed) { if (disposing) /*Dispose managed resources*/ } { CL.ReleaseKernel(KernelId); } }
static void Main(string[] args) { CL _cl = new CL(); int j = ((NCL.IDNA)_cl).DNA(); // NCE.Program _pr = new NCE.Program(); int k = ((NCE.IDNA)_pr).DNA(); }
public long GetContextInfoAsLong(CL param_name) { uint sizeBuffer = 0; long ret = 0; cl.clGetContextInfo(m_pHandle, (uint)param_name, out ret, ref sizeBuffer); return(ret); }
public int GetContextInfoAsInt(CL param_name) { uint sizeBuffer = 0; int ret = 0; cl.clGetContextInfo(m_pHandle, (uint)param_name, out ret, ref sizeBuffer); return(ret); }
public string GetContextInfo(CL param_name) { uint sizeBuffer = 0; string ret = ""; cl.clGetContextInfo(m_pHandle, (uint)param_name, out ret, ref sizeBuffer); return(ret); }
public SpectrumCreatorGPU(AudioContainer audioContainer) : base(audioContainer) { _cl = CL.GetApi(); InitializePlatformId(); InitializeDeviceId(); CreateContext(); CreateCommandQueue(); BuildProgram(); }
public static int Main(string[] args) { int result; sa = 0; sb = 0; result = DoIt(ref sa); if ((result != 4) || (sa != 3)) { Console.WriteLine("testcase 0 FAILED, result is {0}, sa is {1}", result, sa); return(1); } sa = 0; result = DoAdd(ref sa); if ((result != 150) || (sa != 3)) { Console.WriteLine("testcase 1 FAILED, result is {0}, sa is {1}", result, sa); return(1); } result = DoSub(ref sa); if ((result != 150) || (sa != 3)) { Console.WriteLine("testcase 2 FAILED, result is {0}, sa is {1}", result, sa); return(1); } sb = 1; result = DoMul(ref sa); if ((result != 150) || (sa != 3)) { Console.WriteLine("testcase 3 FAILED, result is {0}, sa is {1}", result, sa); return(1); } result = DoDiv(ref sa); if ((result != 150) || (sa != 3)) { Console.WriteLine("testcase 4 FAILED, result is {0}, sa is {1}", result, sa); return(1); } CL CL1 = new CL(); CL1.item = 10; if (CL1.item * 2 < 30) { CL1.item = CL1.item * 2; } else { CL1.item = 5 * (CL1.item * 2); } if (CL1.item * 2 != 40) { Console.WriteLine("testcase 5 FAILED, CL1.item is {0}", CL1.item); return(1); } Console.WriteLine("PASSED"); return(0); }
protected virtual void Dispose(bool disposing) { if (!this.disposed) { if (disposing) /*Dispose managed resources*/ } { CL.ReleaseCommandQueue(CommandQueueId); CL.ReleaseContext(ContextId); } }
private static int Main() { Console.WriteLine("Testing method of 25 parameters, mixed data type"); VT vt = new VT(); vt.m = 11; CL cl = new CL(12); int sum = f(1, 2, 3, 4, 5, 6, 7, 8, 9, new int[1] { 10 }, vt, cl, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25); if (sum == 325) return 100; else return 1; }
private static int f1(short a1, ushort a2, int a3, uint a4, long a5, ulong a6, byte a7, sbyte a8, Decimal a9, int[] a10, VT a11, CL a12, int a13, int a14, int a15, int a16, int a17, int a18, int a19, int a20, int a21, int a22, int a23, int a24, int a25) { int sum = (int)(a1 + a2 + a3 + a4 + (int)a5 + (int)a6 + a7 + a8 + (int)a9 + a10[0] + a11.m + a12.n + a13 + a14 + a15 + a16 + a17 + a18 + a19 + a20 + a21 + a22 + a23 + a24 + a25); Console.WriteLine("The sum is {0}", sum); return sum; }
public static long Func(CL cl, VT vt) { vtstatic.a1 = 18; vtstatic.a2 = 2; vtstatic.a3 = 5L; vtstatic.a4 = 35; vtstatic.a5 = 8; vtstatic.a6 = -6L; vtstatic.a7 = 1L; long retval = Convert.ToInt64((((long)(Convert.ToInt32(cl.a0 / vtstatic.a5) + (long)(Convert.ToInt32(57) - (long)(-70L))) + (long)(vt.a6 * vt.a4)) + (long)((long)(Convert.ToInt32(1787522586) - (long)((vtstatic.a3 + (long)(Convert.ToInt32(1787522586) - (long)(56L))))) * (vt.a4 - vtstatic.a1)) - (long)(vtstatic.a7 * vt.a2))); return retval; }
public static int Main() { VT vt = new VT(); vt.a1 = 5; vt.a2 = 1; vt.a3 = 4L; vt.a4 = 3; vt.a5 = 2; vt.a6 = -1L; vt.a7 = 6L; CL cl = new CL(); long val = Func(cl, vt); return 100; }
public static int Main() { CL cl = new CL(); float[] arr1d = new float[11]; double a4 = 3; arr1d[0] = 4F; long a1 = 6L; vtstatic.a3 = 13; Console.WriteLine("The correct result is 1"); Console.Write("The actual result is "); int retval = Convert.ToInt32(Convert.ToInt32((long)(Convert.ToInt32(vtstatic.a3) + (long)(18L / cl.a5 / 3)) / (cl.a5 * a1 / a4) + (cl.a2 / arr1d[0] - cl.a2))); Console.WriteLine(retval); return retval + 99; }
public static int Main() { CL cl = new CL(); VT_1 vt_1 = new VT_1(); vt_1.a0_1 = 18266; vt_1.a1_1 = 2092284849; vt_1.a4_1 = 5669860955911480750L; ulong val_1 = Func_1(vt_1); if ((cl.a0) > (Convert.ToUInt64(cl.a0 - val_1))) Console.WriteLine("Func: > true"); else Console.WriteLine("Func: > false"); ulong retval = Convert.ToUInt64(Convert.ToUInt64(cl.a0 - val_1)); return 100; }
public static int Main() { double a5 = -0.5; VT vt = new VT(); vt.a1 = 6; vt.a2 = 3L; vt.a3 = 1L; CL cl = new CL(); cl.arr1d[0] = 0.2; vtstatic.a1 = 9; vtstatic.a2 = 0L; vtstatic.a3 = 1L; long retval = (long)(Convert.ToInt32((Convert.ToInt32(((double)(vtstatic.a3 * (vt.a1 - cl.arr1d[0]))) - (vt.a1 - (a5))))) - (long)(((vtstatic.a3 + vtstatic.a2) + (vtstatic.a3 + 5L)))); Console.WriteLine("The correct value is -8"); Console.WriteLine("The actual value is {0}", retval); return 100; }
public static int Main(string[] args) { int result; s_sa = 0; s_sb = 0; result = DoIt(ref s_sa); if ((result != 4) || (s_sa != 3)) { Console.WriteLine("testcase 0 FAILED, result is {0}, sa is {1}", result, s_sa); return 1; } s_sa = 0; result = DoAdd(ref s_sa); if ((result != 150) || (s_sa != 3)) { Console.WriteLine("testcase 1 FAILED, result is {0}, sa is {1}", result, s_sa); return 1; } result = DoSub(ref s_sa); if ((result != 150) || (s_sa != 3)) { Console.WriteLine("testcase 2 FAILED, result is {0}, sa is {1}", result, s_sa); return 1; } s_sb = 1; result = DoMul(ref s_sa); if ((result != 150) || (s_sa != 3)) { Console.WriteLine("testcase 3 FAILED, result is {0}, sa is {1}", result, s_sa); return 1; } result = DoDiv(ref s_sa); if ((result != 150) || (s_sa != 3)) { Console.WriteLine("testcase 4 FAILED, result is {0}, sa is {1}", result, s_sa); return 1; } CL CL1 = new CL(); CL1.item = 10; if (CL1.item * 2 < 30) { CL1.item = CL1.item * 2; } else { CL1.item = 5 * (CL1.item * 2); } if (CL1.item * 2 != 40) { Console.WriteLine("testcase 5 FAILED, CL1.item is {0}", CL1.item); return 1; } Console.WriteLine("PASSED"); return 100; }
public static int Main() { bool pass = true; float temp; float[] arr = new float[3]; VT vt1; CL cl1 = new CL(); //*** add *** Console.WriteLine(); Console.WriteLine("***add***"); //local, in-line if (((float)(s_f1 + s_delta1)) != s_f1) { Console.WriteLine("((float)(f1+delta1))!=f1"); pass = false; } //local temp = s_f1 + s_delta1; if (((float)temp) != s_f1) { Console.WriteLine("((float)temp)!=f1, temp=f1+delta1"); pass = false; } //method call if (((float)floatadd()) != s_f1) { Console.WriteLine("((float)floatadd())!=f1"); pass = false; } //inline method call if (((float)floatadd_inline()) != s_f1) { Console.WriteLine("((float)floatadd_inline())!=f1"); pass = false; } //array element arr[0] = s_f1; arr[1] = s_delta1; arr[2] = arr[0] + arr[1]; if (((float)arr[2]) != s_f1) { Console.WriteLine("((float)arr[2])!=f1"); pass = false; } //struct vt1.f1 = 1.0F; vt1.delta1 = 1.0E-10F; vt1.temp = vt1.f1 + vt1.delta1; if (((float)vt1.temp) != s_f1) { Console.WriteLine("((float)vt1.temp)!=f1"); pass = false; } //class cl1.temp = cl1.f1 + cl1.delta1; if (((float)cl1.temp) != s_f1) { Console.WriteLine("((float)cl1.temp)!=f1"); pass = false; } //*** minus *** Console.WriteLine(); Console.WriteLine("***sub***"); //local, in-line if (((float)(s_f1 - s_delta1)) != s_f1) { Console.WriteLine("((float)(f1-delta1))!=f1"); pass = false; } //local temp = s_f1 - s_delta1; if (((float)temp) != s_f1) { Console.WriteLine("((float)temp)!=f1, temp=f1-delta1"); pass = false; } //method call if (((float)floatsub()) != s_f1) { Console.WriteLine("((float)floatsub())!=f1"); pass = false; } //inline method call if (((float)floatsub_inline()) != s_f1) { Console.WriteLine("((float)floatsub_inline())!=f1"); pass = false; } //array element arr[0] = s_f1; arr[1] = s_delta1; arr[2] = arr[0] - arr[1]; if (((float)arr[2]) != s_f1) { Console.WriteLine("((float)arr[2])!=f1"); pass = false; } //struct vt1.f1 = 1.0F; vt1.delta1 = 1.0E-10F; vt1.temp = vt1.f1 - vt1.delta1; if (((float)vt1.temp) != s_f1) { Console.WriteLine("((float)vt1.temp)!=f1"); pass = false; } //class cl1.temp = cl1.f1 - cl1.delta1; if (((float)cl1.temp) != s_f1) { Console.WriteLine("((float)cl1.temp)!=f1"); pass = false; } //*** multiply *** Console.WriteLine(); Console.WriteLine("***mul***"); //local, in-line if (((float)(s_a1 * s_b1)) != s_f1) { Console.WriteLine("((float)(a1*b1))!=f1"); pass = false; } //local temp = s_a1 * s_b1; if (((float)temp) != s_f1) { Console.WriteLine("((float)temp)!=f1, temp=a1*b1"); pass = false; } //method call if (((float)floatmul()) != s_f1) { Console.WriteLine("((float)floatmul())!=f1"); pass = false; } //inline method call if (((float)floatmul_inline()) != s_f1) { Console.WriteLine("((float)floatmul_inline())!=f1"); pass = false; } //array element arr[0] = s_a1; arr[1] = s_b1; arr[2] = arr[0] * arr[1]; if (((float)arr[2]) != s_f1) { Console.WriteLine("((float)arr[2])!=f1"); pass = false; } //struct vt1.a1 = 3; vt1.b1 = 1.0F / 3.0F; vt1.temp = vt1.a1 * vt1.b1; if (((float)vt1.temp) != s_f1) { Console.WriteLine("((float)vt1.temp)!=f1"); pass = false; } //class cl1.temp = cl1.a1 * cl1.b1; if (((float)cl1.temp) != s_f1) { Console.WriteLine("((float)cl1.temp)!=f1"); pass = false; } //*** divide *** Console.WriteLine(); Console.WriteLine("***div***"); //local, in-line if (((float)(s_f1 / s_a1)) != s_b1) { Console.WriteLine("((float)(f1/a1))!=b1"); pass = false; } //local temp = s_f1 / s_a1; if (((float)temp) != s_b1) { Console.WriteLine("((float)temp)!=f1, temp=f1/a1"); pass = false; } //method call if (((float)floatdiv()) != s_b1) { Console.WriteLine("((float)floatdivl())!=b1"); pass = false; } //method call if (((float)floatdiv_inline()) != s_b1) { Console.WriteLine("((float)floatdiv_inline())!=b1"); pass = false; } //array element arr[0] = s_f1; arr[1] = s_a1; arr[2] = arr[0] / arr[1]; if (((float)arr[2]) != s_b1) { Console.WriteLine("((float)arr[2])!=b1"); pass = false; } //struct vt1.f1 = 1.0F; vt1.a1 = 3; vt1.temp = vt1.f1 / vt1.a1; if (((float)vt1.temp) != s_b1) { Console.WriteLine("((float)vt1.temp)!=b1"); pass = false; } //class cl1.temp = cl1.f1 / cl1.a1; if (((float)cl1.temp) != s_b1) { Console.WriteLine("((float)cl1.temp)!=b1"); pass = false; } Console.WriteLine(); if (pass) { Console.WriteLine("SUCCESS"); return 100; } else { Console.WriteLine("FAILURE: float not truncated properly"); return 1; } }
public static int Main() { bool passed = true; String str2 = "test string"; String[] str1darr = { "string access", "test string" }; Char[,] c2darr = { { '0', '1', '2', '3', '4', '5', '6' }, { 'a', 'b', 'c', 'd', 'e', 'f', 'g' } }; CL cl1 = new CL(); VT vt1; vt1.str = "test string"; char b0, b1, b2, b3, b4, b5, b6; //accessing the strings at different indices. assign to local char b0 = str2[0]; b1 = str1[0]; b2 = cl1.str[0]; b3 = vt1.str[0]; b4 = str1darr[1][0]; b5 = str2darr[0, 0][0]; b6 = f(ref str2)[0]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; if ((str2[4] != str1[4]) || (str1[4] != cl1.str[4]) || (cl1.str[4] != vt1.str[4]) || (vt1.str[4] != str1darr[1][4]) || (str1darr[1][4] != str2darr[0, 0][4]) || (str2darr[0, 0][4] != f(ref str2)[4])) passed = false; b0 = str2[10]; b1 = str1[10]; b2 = cl1.str[10]; b3 = vt1.str[10]; b4 = str1darr[1][10]; b5 = str2darr[0, 0][10]; b6 = f(ref str2)[10]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; int j = rand.Next(0, 10); b0 = str2[j]; b1 = str1[j]; b2 = cl1.str[j]; b3 = vt1.str[j]; b4 = str1darr[1][j]; b5 = str2darr[0, 0][j]; b6 = f(ref str2)[j]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; //accessing the strings at different indices, assign to static char sb0 = str2[1]; sb1 = str1[1]; sb2 = cl1.str[1]; sb3 = vt1.str[1]; sb4 = str1darr[1][1]; sb5 = str2darr[0, 0][1]; sb6 = f(ref str2)[1]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6)) passed = false; if ((str2[5] != str1[5]) || (str1[5] != cl1.str[5]) || (cl1.str[5] != vt1.str[5]) || (vt1.str[5] != str1darr[1][5]) || (str1darr[1][5] != str2darr[0, 0][5]) || (str2darr[0, 0][5] != f(ref str2)[5])) passed = false; sb0 = str2[9]; sb1 = str1[9]; sb2 = cl1.str[9]; sb3 = vt1.str[9]; sb4 = str1darr[1][9]; sb5 = str2darr[0, 0][9]; sb6 = f(ref str2)[9]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6)) passed = false; j = rand.Next(0, 10); sb0 = str2[j]; sb1 = str1[j]; sb2 = cl1.str[j]; sb3 = vt1.str[j]; sb4 = str1darr[1][j]; sb5 = str2darr[0, 0][j]; sb6 = f(ref str2)[j]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6)) passed = false; //accessing the strings at different indices, assign to VT char vt1.b0 = str2[2]; vt1.b1 = str1[2]; vt1.b2 = cl1.str[2]; vt1.b3 = vt1.str[2]; vt1.b4 = str1darr[1][2]; vt1.b5 = str2darr[0, 0][2]; vt1.b6 = f(ref str2)[2]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; if ((str2[6] != str1[6]) || (str1[6] != cl1.str[6]) || (cl1.str[6] != vt1.str[6]) || (vt1.str[6] != str1darr[1][6]) || (str1darr[1][6] != str2darr[0, 0][6]) || (str2darr[0, 0][6] != f(ref str2)[6])) passed = false; vt1.b0 = str2[8]; vt1.b1 = str1[8]; vt1.b2 = cl1.str[8]; vt1.b3 = vt1.str[8]; vt1.b4 = str1darr[1][8]; vt1.b5 = str2darr[0, 0][8]; vt1.b6 = f(ref str2)[8]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; j = rand.Next(0, 10); vt1.b0 = str2[j]; vt1.b1 = str1[j]; vt1.b2 = cl1.str[j]; vt1.b3 = vt1.str[j]; vt1.b4 = str1darr[1][j]; vt1.b5 = str2darr[0, 0][j]; vt1.b6 = f(ref str2)[j]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; //accessing the strings at different indices, assign to CL char cl1.b0 = str2[7]; cl1.b1 = str1[7]; cl1.b2 = cl1.str[7]; cl1.b3 = vt1.str[7]; cl1.b4 = str1darr[1][7]; cl1.b5 = str2darr[0, 0][7]; cl1.b6 = f(ref str2)[7]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6)) passed = false; if ((str2[0] != str1[0]) || (str1[0] != cl1.str[0]) || (cl1.str[0] != vt1.str[0]) || (vt1.str[0] != str1darr[1][0]) || (str1darr[1][0] != str2darr[0, 0][0]) || (str2darr[0, 0][0] != f(ref str2)[0])) passed = false; cl1.b0 = str2[4]; cl1.b1 = str1[4]; cl1.b2 = cl1.str[4]; cl1.b3 = vt1.str[4]; cl1.b4 = str1darr[1][4]; cl1.b5 = str2darr[0, 0][4]; cl1.b6 = f(ref str2)[4]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6)) passed = false; j = rand.Next(0, 10); cl1.b0 = str2[j]; cl1.b1 = str1[j]; cl1.b2 = cl1.str[j]; cl1.b3 = vt1.str[j]; cl1.b4 = str1darr[1][j]; cl1.b5 = str2darr[0, 0][j]; cl1.b6 = f(ref str2)[j]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6)) passed = false; //accessing the strings at different indices, assign to 2d array char c2darr[1, 0] = str2[6]; c2darr[1, 1] = str1[6]; c2darr[1, 2] = cl1.str[6]; c2darr[1, 3] = vt1.str[6]; c2darr[1, 4] = str1darr[1][6]; c2darr[1, 5] = str2darr[0, 0][6]; c2darr[1, 6] = f(ref str2)[6]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6])) passed = false; if ((str2[0] != str1[0]) || (str1[0] != cl1.str[0]) || (cl1.str[0] != vt1.str[0]) || (vt1.str[0] != str1darr[1][0]) || (str1darr[1][0] != str2darr[0, 0][0]) || (str2darr[0, 0][0] != f(ref str2)[0])) passed = false; c2darr[1, 0] = str2[6]; c2darr[1, 1] = str1[6]; c2darr[1, 2] = cl1.str[6]; c2darr[1, 3] = vt1.str[6]; c2darr[1, 4] = str1darr[1][6]; c2darr[1, 5] = str2darr[0, 0][6]; c2darr[1, 6] = f(ref str2)[6]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6])) passed = false; j = rand.Next(0, 10); c2darr[1, 0] = str2[j]; c2darr[1, 1] = str1[j]; c2darr[1, 2] = cl1.str[j]; c2darr[1, 3] = vt1.str[j]; c2darr[1, 4] = str1darr[1][j]; c2darr[1, 5] = str2darr[0, 0][j]; c2darr[1, 6] = f(ref str2)[j]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6])) passed = false; if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.byte2darr = new byte[,] { { 0, 1 }, { 0, 0 } }; vt1.byte3darr = new byte[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; vt1.byte2darr_b = new byte[,] { { 0, 49 }, { 0, 0 } }; vt1.byte3darr_b = new byte[,,] { { { 0, 0 } }, { { 0, 49 } }, { { 0, 0 } } }; CL cl1 = new CL(); ja1[0] = new byte[,] { { 0, 1 }, { 0, 0 } }; ja2[1] = new byte[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; ja1_b[0] = new byte[,] { { 0, 49 }, { 0, 0 } }; ja2_b[1] = new byte[,,] { { { 0, 0 } }, { { 0, 49 } }, { { 0, 0 } } }; byte result = 1; // 2D if (result != byte2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.byte2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.byte2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != byte3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.byte3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.byte3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToBool tests bool Bool_result = true; // 2D if (Bool_result != Convert.ToBoolean(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Bool_result != Convert.ToBoolean(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToDecimal tests decimal Decimal_result = 1; // 2D if (Decimal_result != Convert.ToDecimal(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Decimal_result != Convert.ToDecimal(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToDouble double Double_result = 1; // 2D if (Double_result != Convert.ToDouble(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Double_result != Convert.ToDouble(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToSingle tests Single Single_result = 1; // 2D if (Single_result != Convert.ToSingle(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Single_result != Convert.ToSingle(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToInt32 tests int Int32_result = 1; // 2D if (Int32_result != Convert.ToInt32(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToInt64 tests long Int64_result = 1; // 2D if (Int64_result != Convert.ToInt64(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int64_result != Convert.ToInt64(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToSByte tests sbyte SByte_result = 1; // 2D if (SByte_result != Convert.ToSByte(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (SByte_result != Convert.ToSByte(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToInt16 tests short Int16_result = 1; // 2D if (Int16_result != Convert.ToInt16(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToUInt32 uint UInt32_result = 1; // 2D if (UInt32_result != Convert.ToUInt32(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToUInt64 ulong UInt64_result = 1; // 2D if (UInt64_result != Convert.ToUInt64(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt64_result != Convert.ToUInt64(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToUInt16 tests short UInt16_result = 1; // 2D if (UInt16_result != Convert.ToUInt16(byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.byte2darr[0, 1] is: {0}", vt1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.byte2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.byte2darr[0, 1] is: {0}", cl1.byte2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("byte3darr[1,0,1] is: {0}", byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.byte3darr[1,0,1] is: {0}", vt1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.byte3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.byte3darr[1,0,1] is: {0}", cl1.byte3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //ByteToChar tests char Char_result = '1'; // 2D if (Char_result != Convert.ToChar(byte2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("2darr[0, 1] is: {0}", byte2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(vt1.byte2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("vt1.byte2darr_b[0, 1] is: {0}", vt1.byte2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(cl1.byte2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("cl1.byte2darr_b[0, 1] is: {0}", cl1.byte2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Char_result != Convert.ToChar(byte3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("byte3darr_b[1,0,1] is: {0}", byte3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(vt1.byte3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("vt1.byte3darr_b[1,0,1] is: {0}", vt1.byte3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(cl1.byte3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("cl1.byte3darr_b[1,0,1] is: {0}", cl1.byte3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.m_vt_op1 = 50; vt1.i_vt_op2 = 2; vt1.ui_vt_op2 = 2; vt1.l_vt_op2 = 2; vt1.ul_vt_op2 = 2; vt1.f_vt_op2 = 2; vt1.d_vt_op2 = 2; vt1.m_vt_op2 = 2; decimal[] m_arr1d_op1 = { 0, 50 }; decimal[,] m_arr2d_op1 = { { 0, 50 }, { 1, 1 } }; decimal[,,] m_arr3d_op1 = { { { 0, 50 }, { 1, 1 } } }; int[] i_arr1d_op2 = { 2, 0, 1 }; int[,] i_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; int[,,] i_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; uint[] ui_arr1d_op2 = { 2, 0, 1 }; uint[,] ui_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; uint[,,] ui_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; long[] l_arr1d_op2 = { 2, 0, 1 }; long[,] l_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; long[,,] l_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; ulong[] ul_arr1d_op2 = { 2, 0, 1 }; ulong[,] ul_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; ulong[,,] ul_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; float[] f_arr1d_op2 = { 2, 0, 1 }; float[,] f_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; float[,,] f_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; double[] d_arr1d_op2 = { 2, 0, 1 }; double[,] d_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; double[,,] d_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; decimal[] m_arr1d_op2 = { 2, 0, 1 }; decimal[,] m_arr2d_op2 = { { 0, 2 }, { 1, 1 } }; decimal[,,] m_arr3d_op2 = { { { 0, 2 }, { 1, 1 } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { decimal m_l_op1 = 50; int i_l_op2 = 2; uint ui_l_op2 = 2; long l_l_op2 = 2; ulong ul_l_op2 = 2; float f_l_op2 = 2; double d_l_op2 = 2; decimal m_l_op2 = 2; if ((m_l_op1 / i_l_op2 != m_l_op1 / ui_l_op2) || (m_l_op1 / ui_l_op2 != m_l_op1 / l_l_op2) || (m_l_op1 / l_l_op2 != m_l_op1 / ul_l_op2) || (m_l_op1 / ul_l_op2 != m_l_op1 / (decimal)f_l_op2) || (m_l_op1 / (decimal)f_l_op2 != m_l_op1 / (decimal)d_l_op2) || (m_l_op1 / (decimal)d_l_op2 != m_l_op1 / m_l_op2) || (m_l_op1 / m_l_op2 != m_l_op1 / i_l_op2) || (m_l_op1 / i_l_op2 != 25)) { Console.WriteLine("testcase 1 failed"); passed = false; } if ((m_l_op1 / s_i_s_op2 != m_l_op1 / s_ui_s_op2) || (m_l_op1 / s_ui_s_op2 != m_l_op1 / s_l_s_op2) || (m_l_op1 / s_l_s_op2 != m_l_op1 / s_ul_s_op2) || (m_l_op1 / s_ul_s_op2 != m_l_op1 / (decimal)s_f_s_op2) || (m_l_op1 / (decimal)s_f_s_op2 != m_l_op1 / (decimal)s_d_s_op2) || (m_l_op1 / (decimal)s_d_s_op2 != m_l_op1 / s_m_s_op2) || (m_l_op1 / s_m_s_op2 != m_l_op1 / s_i_s_op2) || (m_l_op1 / s_i_s_op2 != 25)) { Console.WriteLine("testcase 2 failed"); passed = false; } if ((m_l_op1 / m_f("op2") != m_l_op1 / m_f("op2")) || (m_l_op1 / m_f("op2") != m_l_op1 / m_f("op2")) || (m_l_op1 / m_f("op2") != m_l_op1 / m_f("op2")) || (m_l_op1 / m_f("op2") != m_l_op1 / (decimal)m_f("op2")) || (m_l_op1 / (decimal)m_f("op2") != m_l_op1 / (decimal)m_f("op2")) || (m_l_op1 / (decimal)m_f("op2") != m_l_op1 / m_f("op2")) || (m_l_op1 / m_f("op2") != m_l_op1 / m_f("op2")) || (m_l_op1 / m_f("op2") != 25)) { Console.WriteLine("testcase 3 failed"); passed = false; } if ((m_l_op1 / cl1.i_cl_op2 != m_l_op1 / cl1.ui_cl_op2) || (m_l_op1 / cl1.ui_cl_op2 != m_l_op1 / cl1.l_cl_op2) || (m_l_op1 / cl1.l_cl_op2 != m_l_op1 / cl1.ul_cl_op2) || (m_l_op1 / cl1.ul_cl_op2 != m_l_op1 / (decimal)cl1.f_cl_op2) || (m_l_op1 / (decimal)cl1.f_cl_op2 != m_l_op1 / (decimal)cl1.d_cl_op2) || (m_l_op1 / (decimal)cl1.d_cl_op2 != m_l_op1 / cl1.m_cl_op2) || (m_l_op1 / cl1.m_cl_op2 != m_l_op1 / cl1.i_cl_op2) || (m_l_op1 / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 4 failed"); passed = false; } if ((m_l_op1 / vt1.i_vt_op2 != m_l_op1 / vt1.ui_vt_op2) || (m_l_op1 / vt1.ui_vt_op2 != m_l_op1 / vt1.l_vt_op2) || (m_l_op1 / vt1.l_vt_op2 != m_l_op1 / vt1.ul_vt_op2) || (m_l_op1 / vt1.ul_vt_op2 != m_l_op1 / (decimal)vt1.f_vt_op2) || (m_l_op1 / (decimal)vt1.f_vt_op2 != m_l_op1 / (decimal)vt1.d_vt_op2) || (m_l_op1 / (decimal)vt1.d_vt_op2 != m_l_op1 / vt1.m_vt_op2) || (m_l_op1 / vt1.m_vt_op2 != m_l_op1 / vt1.i_vt_op2) || (m_l_op1 / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 5 failed"); passed = false; } if ((m_l_op1 / i_arr1d_op2[0] != m_l_op1 / ui_arr1d_op2[0]) || (m_l_op1 / ui_arr1d_op2[0] != m_l_op1 / l_arr1d_op2[0]) || (m_l_op1 / l_arr1d_op2[0] != m_l_op1 / ul_arr1d_op2[0]) || (m_l_op1 / ul_arr1d_op2[0] != m_l_op1 / (decimal)f_arr1d_op2[0]) || (m_l_op1 / (decimal)f_arr1d_op2[0] != m_l_op1 / (decimal)d_arr1d_op2[0]) || (m_l_op1 / (decimal)d_arr1d_op2[0] != m_l_op1 / m_arr1d_op2[0]) || (m_l_op1 / m_arr1d_op2[0] != m_l_op1 / i_arr1d_op2[0]) || (m_l_op1 / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 6 failed"); passed = false; } if ((m_l_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / l_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / l_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / m_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / m_arr2d_op2[index[0, 1], index[1, 0]] != m_l_op1 / i_arr2d_op2[index[0, 1], index[1, 0]]) || (m_l_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 7 failed"); passed = false; } if ((m_l_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_l_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_l_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 8 failed"); passed = false; } if ((s_m_s_op1 / i_l_op2 != s_m_s_op1 / ui_l_op2) || (s_m_s_op1 / ui_l_op2 != s_m_s_op1 / l_l_op2) || (s_m_s_op1 / l_l_op2 != s_m_s_op1 / ul_l_op2) || (s_m_s_op1 / ul_l_op2 != s_m_s_op1 / (decimal)f_l_op2) || (s_m_s_op1 / (decimal)f_l_op2 != s_m_s_op1 / (decimal)d_l_op2) || (s_m_s_op1 / (decimal)d_l_op2 != s_m_s_op1 / m_l_op2) || (s_m_s_op1 / m_l_op2 != s_m_s_op1 / i_l_op2) || (s_m_s_op1 / i_l_op2 != 25)) { Console.WriteLine("testcase 9 failed"); passed = false; } if ((s_m_s_op1 / s_i_s_op2 != s_m_s_op1 / s_ui_s_op2) || (s_m_s_op1 / s_ui_s_op2 != s_m_s_op1 / s_l_s_op2) || (s_m_s_op1 / s_l_s_op2 != s_m_s_op1 / s_ul_s_op2) || (s_m_s_op1 / s_ul_s_op2 != s_m_s_op1 / (decimal)s_f_s_op2) || (s_m_s_op1 / (decimal)s_f_s_op2 != s_m_s_op1 / (decimal)s_d_s_op2) || (s_m_s_op1 / (decimal)s_d_s_op2 != s_m_s_op1 / s_m_s_op2) || (s_m_s_op1 / s_m_s_op2 != s_m_s_op1 / s_i_s_op2) || (s_m_s_op1 / s_i_s_op2 != 25)) { Console.WriteLine("testcase 10 failed"); passed = false; } if ((s_m_s_op1 / m_f("op2") != s_m_s_op1 / m_f("op2")) || (s_m_s_op1 / m_f("op2") != s_m_s_op1 / m_f("op2")) || (s_m_s_op1 / m_f("op2") != s_m_s_op1 / m_f("op2")) || (s_m_s_op1 / m_f("op2") != s_m_s_op1 / (decimal)m_f("op2")) || (s_m_s_op1 / (decimal)m_f("op2") != s_m_s_op1 / (decimal)m_f("op2")) || (s_m_s_op1 / (decimal)m_f("op2") != s_m_s_op1 / m_f("op2")) || (s_m_s_op1 / m_f("op2") != s_m_s_op1 / m_f("op2")) || (s_m_s_op1 / m_f("op2") != 25)) { Console.WriteLine("testcase 11 failed"); passed = false; } if ((s_m_s_op1 / cl1.i_cl_op2 != s_m_s_op1 / cl1.ui_cl_op2) || (s_m_s_op1 / cl1.ui_cl_op2 != s_m_s_op1 / cl1.l_cl_op2) || (s_m_s_op1 / cl1.l_cl_op2 != s_m_s_op1 / cl1.ul_cl_op2) || (s_m_s_op1 / cl1.ul_cl_op2 != s_m_s_op1 / (decimal)cl1.f_cl_op2) || (s_m_s_op1 / (decimal)cl1.f_cl_op2 != s_m_s_op1 / (decimal)cl1.d_cl_op2) || (s_m_s_op1 / (decimal)cl1.d_cl_op2 != s_m_s_op1 / cl1.m_cl_op2) || (s_m_s_op1 / cl1.m_cl_op2 != s_m_s_op1 / cl1.i_cl_op2) || (s_m_s_op1 / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 12 failed"); passed = false; } if ((s_m_s_op1 / vt1.i_vt_op2 != s_m_s_op1 / vt1.ui_vt_op2) || (s_m_s_op1 / vt1.ui_vt_op2 != s_m_s_op1 / vt1.l_vt_op2) || (s_m_s_op1 / vt1.l_vt_op2 != s_m_s_op1 / vt1.ul_vt_op2) || (s_m_s_op1 / vt1.ul_vt_op2 != s_m_s_op1 / (decimal)vt1.f_vt_op2) || (s_m_s_op1 / (decimal)vt1.f_vt_op2 != s_m_s_op1 / (decimal)vt1.d_vt_op2) || (s_m_s_op1 / (decimal)vt1.d_vt_op2 != s_m_s_op1 / vt1.m_vt_op2) || (s_m_s_op1 / vt1.m_vt_op2 != s_m_s_op1 / vt1.i_vt_op2) || (s_m_s_op1 / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 13 failed"); passed = false; } if ((s_m_s_op1 / i_arr1d_op2[0] != s_m_s_op1 / ui_arr1d_op2[0]) || (s_m_s_op1 / ui_arr1d_op2[0] != s_m_s_op1 / l_arr1d_op2[0]) || (s_m_s_op1 / l_arr1d_op2[0] != s_m_s_op1 / ul_arr1d_op2[0]) || (s_m_s_op1 / ul_arr1d_op2[0] != s_m_s_op1 / (decimal)f_arr1d_op2[0]) || (s_m_s_op1 / (decimal)f_arr1d_op2[0] != s_m_s_op1 / (decimal)d_arr1d_op2[0]) || (s_m_s_op1 / (decimal)d_arr1d_op2[0] != s_m_s_op1 / m_arr1d_op2[0]) || (s_m_s_op1 / m_arr1d_op2[0] != s_m_s_op1 / i_arr1d_op2[0]) || (s_m_s_op1 / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 14 failed"); passed = false; } if ((s_m_s_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / l_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / l_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / m_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / m_arr2d_op2[index[0, 1], index[1, 0]] != s_m_s_op1 / i_arr2d_op2[index[0, 1], index[1, 0]]) || (s_m_s_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 15 failed"); passed = false; } if ((s_m_s_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_m_s_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_m_s_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 16 failed"); passed = false; } if ((m_f("op1") / i_l_op2 != m_f("op1") / ui_l_op2) || (m_f("op1") / ui_l_op2 != m_f("op1") / l_l_op2) || (m_f("op1") / l_l_op2 != m_f("op1") / ul_l_op2) || (m_f("op1") / ul_l_op2 != m_f("op1") / (decimal)f_l_op2) || (m_f("op1") / (decimal)f_l_op2 != m_f("op1") / (decimal)d_l_op2) || (m_f("op1") / (decimal)d_l_op2 != m_f("op1") / m_l_op2) || (m_f("op1") / m_l_op2 != m_f("op1") / i_l_op2) || (m_f("op1") / i_l_op2 != 25)) { Console.WriteLine("testcase 17 failed"); passed = false; } if ((m_f("op1") / s_i_s_op2 != m_f("op1") / s_ui_s_op2) || (m_f("op1") / s_ui_s_op2 != m_f("op1") / s_l_s_op2) || (m_f("op1") / s_l_s_op2 != m_f("op1") / s_ul_s_op2) || (m_f("op1") / s_ul_s_op2 != m_f("op1") / (decimal)s_f_s_op2) || (m_f("op1") / (decimal)s_f_s_op2 != m_f("op1") / (decimal)s_d_s_op2) || (m_f("op1") / (decimal)s_d_s_op2 != m_f("op1") / s_m_s_op2) || (m_f("op1") / s_m_s_op2 != m_f("op1") / s_i_s_op2) || (m_f("op1") / s_i_s_op2 != 25)) { Console.WriteLine("testcase 18 failed"); passed = false; } if ((m_f("op1") / m_f("op2") != m_f("op1") / m_f("op2")) || (m_f("op1") / m_f("op2") != m_f("op1") / m_f("op2")) || (m_f("op1") / m_f("op2") != m_f("op1") / m_f("op2")) || (m_f("op1") / m_f("op2") != m_f("op1") / (decimal)m_f("op2")) || (m_f("op1") / (decimal)m_f("op2") != m_f("op1") / (decimal)m_f("op2")) || (m_f("op1") / (decimal)m_f("op2") != m_f("op1") / m_f("op2")) || (m_f("op1") / m_f("op2") != m_f("op1") / m_f("op2")) || (m_f("op1") / m_f("op2") != 25)) { Console.WriteLine("testcase 19 failed"); passed = false; } if ((m_f("op1") / cl1.i_cl_op2 != m_f("op1") / cl1.ui_cl_op2) || (m_f("op1") / cl1.ui_cl_op2 != m_f("op1") / cl1.l_cl_op2) || (m_f("op1") / cl1.l_cl_op2 != m_f("op1") / cl1.ul_cl_op2) || (m_f("op1") / cl1.ul_cl_op2 != m_f("op1") / (decimal)cl1.f_cl_op2) || (m_f("op1") / (decimal)cl1.f_cl_op2 != m_f("op1") / (decimal)cl1.d_cl_op2) || (m_f("op1") / (decimal)cl1.d_cl_op2 != m_f("op1") / cl1.m_cl_op2) || (m_f("op1") / cl1.m_cl_op2 != m_f("op1") / cl1.i_cl_op2) || (m_f("op1") / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 20 failed"); passed = false; } if ((m_f("op1") / vt1.i_vt_op2 != m_f("op1") / vt1.ui_vt_op2) || (m_f("op1") / vt1.ui_vt_op2 != m_f("op1") / vt1.l_vt_op2) || (m_f("op1") / vt1.l_vt_op2 != m_f("op1") / vt1.ul_vt_op2) || (m_f("op1") / vt1.ul_vt_op2 != m_f("op1") / (decimal)vt1.f_vt_op2) || (m_f("op1") / (decimal)vt1.f_vt_op2 != m_f("op1") / (decimal)vt1.d_vt_op2) || (m_f("op1") / (decimal)vt1.d_vt_op2 != m_f("op1") / vt1.m_vt_op2) || (m_f("op1") / vt1.m_vt_op2 != m_f("op1") / vt1.i_vt_op2) || (m_f("op1") / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 21 failed"); passed = false; } if ((m_f("op1") / i_arr1d_op2[0] != m_f("op1") / ui_arr1d_op2[0]) || (m_f("op1") / ui_arr1d_op2[0] != m_f("op1") / l_arr1d_op2[0]) || (m_f("op1") / l_arr1d_op2[0] != m_f("op1") / ul_arr1d_op2[0]) || (m_f("op1") / ul_arr1d_op2[0] != m_f("op1") / (decimal)f_arr1d_op2[0]) || (m_f("op1") / (decimal)f_arr1d_op2[0] != m_f("op1") / (decimal)d_arr1d_op2[0]) || (m_f("op1") / (decimal)d_arr1d_op2[0] != m_f("op1") / m_arr1d_op2[0]) || (m_f("op1") / m_arr1d_op2[0] != m_f("op1") / i_arr1d_op2[0]) || (m_f("op1") / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 22 failed"); passed = false; } if ((m_f("op1") / i_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / ui_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / l_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / l_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / ul_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / m_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / m_arr2d_op2[index[0, 1], index[1, 0]] != m_f("op1") / i_arr2d_op2[index[0, 1], index[1, 0]]) || (m_f("op1") / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 23 failed"); passed = false; } if ((m_f("op1") / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_f("op1") / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_f("op1") / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 24 failed"); passed = false; } if ((cl1.m_cl_op1 / i_l_op2 != cl1.m_cl_op1 / ui_l_op2) || (cl1.m_cl_op1 / ui_l_op2 != cl1.m_cl_op1 / l_l_op2) || (cl1.m_cl_op1 / l_l_op2 != cl1.m_cl_op1 / ul_l_op2) || (cl1.m_cl_op1 / ul_l_op2 != cl1.m_cl_op1 / (decimal)f_l_op2) || (cl1.m_cl_op1 / (decimal)f_l_op2 != cl1.m_cl_op1 / (decimal)d_l_op2) || (cl1.m_cl_op1 / (decimal)d_l_op2 != cl1.m_cl_op1 / m_l_op2) || (cl1.m_cl_op1 / m_l_op2 != cl1.m_cl_op1 / i_l_op2) || (cl1.m_cl_op1 / i_l_op2 != 25)) { Console.WriteLine("testcase 25 failed"); passed = false; } if ((cl1.m_cl_op1 / s_i_s_op2 != cl1.m_cl_op1 / s_ui_s_op2) || (cl1.m_cl_op1 / s_ui_s_op2 != cl1.m_cl_op1 / s_l_s_op2) || (cl1.m_cl_op1 / s_l_s_op2 != cl1.m_cl_op1 / s_ul_s_op2) || (cl1.m_cl_op1 / s_ul_s_op2 != cl1.m_cl_op1 / (decimal)s_f_s_op2) || (cl1.m_cl_op1 / (decimal)s_f_s_op2 != cl1.m_cl_op1 / (decimal)s_d_s_op2) || (cl1.m_cl_op1 / (decimal)s_d_s_op2 != cl1.m_cl_op1 / s_m_s_op2) || (cl1.m_cl_op1 / s_m_s_op2 != cl1.m_cl_op1 / s_i_s_op2) || (cl1.m_cl_op1 / s_i_s_op2 != 25)) { Console.WriteLine("testcase 26 failed"); passed = false; } if ((cl1.m_cl_op1 / m_f("op2") != cl1.m_cl_op1 / m_f("op2")) || (cl1.m_cl_op1 / m_f("op2") != cl1.m_cl_op1 / m_f("op2")) || (cl1.m_cl_op1 / m_f("op2") != cl1.m_cl_op1 / m_f("op2")) || (cl1.m_cl_op1 / m_f("op2") != cl1.m_cl_op1 / (decimal)m_f("op2")) || (cl1.m_cl_op1 / (decimal)m_f("op2") != cl1.m_cl_op1 / (decimal)m_f("op2")) || (cl1.m_cl_op1 / (decimal)m_f("op2") != cl1.m_cl_op1 / m_f("op2")) || (cl1.m_cl_op1 / m_f("op2") != cl1.m_cl_op1 / m_f("op2")) || (cl1.m_cl_op1 / m_f("op2") != 25)) { Console.WriteLine("testcase 27 failed"); passed = false; } if ((cl1.m_cl_op1 / cl1.i_cl_op2 != cl1.m_cl_op1 / cl1.ui_cl_op2) || (cl1.m_cl_op1 / cl1.ui_cl_op2 != cl1.m_cl_op1 / cl1.l_cl_op2) || (cl1.m_cl_op1 / cl1.l_cl_op2 != cl1.m_cl_op1 / cl1.ul_cl_op2) || (cl1.m_cl_op1 / cl1.ul_cl_op2 != cl1.m_cl_op1 / (decimal)cl1.f_cl_op2) || (cl1.m_cl_op1 / (decimal)cl1.f_cl_op2 != cl1.m_cl_op1 / (decimal)cl1.d_cl_op2) || (cl1.m_cl_op1 / (decimal)cl1.d_cl_op2 != cl1.m_cl_op1 / cl1.m_cl_op2) || (cl1.m_cl_op1 / cl1.m_cl_op2 != cl1.m_cl_op1 / cl1.i_cl_op2) || (cl1.m_cl_op1 / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 28 failed"); passed = false; } if ((cl1.m_cl_op1 / vt1.i_vt_op2 != cl1.m_cl_op1 / vt1.ui_vt_op2) || (cl1.m_cl_op1 / vt1.ui_vt_op2 != cl1.m_cl_op1 / vt1.l_vt_op2) || (cl1.m_cl_op1 / vt1.l_vt_op2 != cl1.m_cl_op1 / vt1.ul_vt_op2) || (cl1.m_cl_op1 / vt1.ul_vt_op2 != cl1.m_cl_op1 / (decimal)vt1.f_vt_op2) || (cl1.m_cl_op1 / (decimal)vt1.f_vt_op2 != cl1.m_cl_op1 / (decimal)vt1.d_vt_op2) || (cl1.m_cl_op1 / (decimal)vt1.d_vt_op2 != cl1.m_cl_op1 / vt1.m_vt_op2) || (cl1.m_cl_op1 / vt1.m_vt_op2 != cl1.m_cl_op1 / vt1.i_vt_op2) || (cl1.m_cl_op1 / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 29 failed"); passed = false; } if ((cl1.m_cl_op1 / i_arr1d_op2[0] != cl1.m_cl_op1 / ui_arr1d_op2[0]) || (cl1.m_cl_op1 / ui_arr1d_op2[0] != cl1.m_cl_op1 / l_arr1d_op2[0]) || (cl1.m_cl_op1 / l_arr1d_op2[0] != cl1.m_cl_op1 / ul_arr1d_op2[0]) || (cl1.m_cl_op1 / ul_arr1d_op2[0] != cl1.m_cl_op1 / (decimal)f_arr1d_op2[0]) || (cl1.m_cl_op1 / (decimal)f_arr1d_op2[0] != cl1.m_cl_op1 / (decimal)d_arr1d_op2[0]) || (cl1.m_cl_op1 / (decimal)d_arr1d_op2[0] != cl1.m_cl_op1 / m_arr1d_op2[0]) || (cl1.m_cl_op1 / m_arr1d_op2[0] != cl1.m_cl_op1 / i_arr1d_op2[0]) || (cl1.m_cl_op1 / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 30 failed"); passed = false; } if ((cl1.m_cl_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / l_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / l_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / m_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / m_arr2d_op2[index[0, 1], index[1, 0]] != cl1.m_cl_op1 / i_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.m_cl_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 31 failed"); passed = false; } if ((cl1.m_cl_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.m_cl_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.m_cl_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 32 failed"); passed = false; } if ((vt1.m_vt_op1 / i_l_op2 != vt1.m_vt_op1 / ui_l_op2) || (vt1.m_vt_op1 / ui_l_op2 != vt1.m_vt_op1 / l_l_op2) || (vt1.m_vt_op1 / l_l_op2 != vt1.m_vt_op1 / ul_l_op2) || (vt1.m_vt_op1 / ul_l_op2 != vt1.m_vt_op1 / (decimal)f_l_op2) || (vt1.m_vt_op1 / (decimal)f_l_op2 != vt1.m_vt_op1 / (decimal)d_l_op2) || (vt1.m_vt_op1 / (decimal)d_l_op2 != vt1.m_vt_op1 / m_l_op2) || (vt1.m_vt_op1 / m_l_op2 != vt1.m_vt_op1 / i_l_op2) || (vt1.m_vt_op1 / i_l_op2 != 25)) { Console.WriteLine("testcase 33 failed"); passed = false; } if ((vt1.m_vt_op1 / s_i_s_op2 != vt1.m_vt_op1 / s_ui_s_op2) || (vt1.m_vt_op1 / s_ui_s_op2 != vt1.m_vt_op1 / s_l_s_op2) || (vt1.m_vt_op1 / s_l_s_op2 != vt1.m_vt_op1 / s_ul_s_op2) || (vt1.m_vt_op1 / s_ul_s_op2 != vt1.m_vt_op1 / (decimal)s_f_s_op2) || (vt1.m_vt_op1 / (decimal)s_f_s_op2 != vt1.m_vt_op1 / (decimal)s_d_s_op2) || (vt1.m_vt_op1 / (decimal)s_d_s_op2 != vt1.m_vt_op1 / s_m_s_op2) || (vt1.m_vt_op1 / s_m_s_op2 != vt1.m_vt_op1 / s_i_s_op2) || (vt1.m_vt_op1 / s_i_s_op2 != 25)) { Console.WriteLine("testcase 34 failed"); passed = false; } if ((vt1.m_vt_op1 / m_f("op2") != vt1.m_vt_op1 / m_f("op2")) || (vt1.m_vt_op1 / m_f("op2") != vt1.m_vt_op1 / m_f("op2")) || (vt1.m_vt_op1 / m_f("op2") != vt1.m_vt_op1 / m_f("op2")) || (vt1.m_vt_op1 / m_f("op2") != vt1.m_vt_op1 / (decimal)m_f("op2")) || (vt1.m_vt_op1 / (decimal)m_f("op2") != vt1.m_vt_op1 / (decimal)m_f("op2")) || (vt1.m_vt_op1 / (decimal)m_f("op2") != vt1.m_vt_op1 / m_f("op2")) || (vt1.m_vt_op1 / m_f("op2") != vt1.m_vt_op1 / m_f("op2")) || (vt1.m_vt_op1 / m_f("op2") != 25)) { Console.WriteLine("testcase 35 failed"); passed = false; } if ((vt1.m_vt_op1 / cl1.i_cl_op2 != vt1.m_vt_op1 / cl1.ui_cl_op2) || (vt1.m_vt_op1 / cl1.ui_cl_op2 != vt1.m_vt_op1 / cl1.l_cl_op2) || (vt1.m_vt_op1 / cl1.l_cl_op2 != vt1.m_vt_op1 / cl1.ul_cl_op2) || (vt1.m_vt_op1 / cl1.ul_cl_op2 != vt1.m_vt_op1 / (decimal)cl1.f_cl_op2) || (vt1.m_vt_op1 / (decimal)cl1.f_cl_op2 != vt1.m_vt_op1 / (decimal)cl1.d_cl_op2) || (vt1.m_vt_op1 / (decimal)cl1.d_cl_op2 != vt1.m_vt_op1 / cl1.m_cl_op2) || (vt1.m_vt_op1 / cl1.m_cl_op2 != vt1.m_vt_op1 / cl1.i_cl_op2) || (vt1.m_vt_op1 / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 36 failed"); passed = false; } if ((vt1.m_vt_op1 / vt1.i_vt_op2 != vt1.m_vt_op1 / vt1.ui_vt_op2) || (vt1.m_vt_op1 / vt1.ui_vt_op2 != vt1.m_vt_op1 / vt1.l_vt_op2) || (vt1.m_vt_op1 / vt1.l_vt_op2 != vt1.m_vt_op1 / vt1.ul_vt_op2) || (vt1.m_vt_op1 / vt1.ul_vt_op2 != vt1.m_vt_op1 / (decimal)vt1.f_vt_op2) || (vt1.m_vt_op1 / (decimal)vt1.f_vt_op2 != vt1.m_vt_op1 / (decimal)vt1.d_vt_op2) || (vt1.m_vt_op1 / (decimal)vt1.d_vt_op2 != vt1.m_vt_op1 / vt1.m_vt_op2) || (vt1.m_vt_op1 / vt1.m_vt_op2 != vt1.m_vt_op1 / vt1.i_vt_op2) || (vt1.m_vt_op1 / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 37 failed"); passed = false; } if ((vt1.m_vt_op1 / i_arr1d_op2[0] != vt1.m_vt_op1 / ui_arr1d_op2[0]) || (vt1.m_vt_op1 / ui_arr1d_op2[0] != vt1.m_vt_op1 / l_arr1d_op2[0]) || (vt1.m_vt_op1 / l_arr1d_op2[0] != vt1.m_vt_op1 / ul_arr1d_op2[0]) || (vt1.m_vt_op1 / ul_arr1d_op2[0] != vt1.m_vt_op1 / (decimal)f_arr1d_op2[0]) || (vt1.m_vt_op1 / (decimal)f_arr1d_op2[0] != vt1.m_vt_op1 / (decimal)d_arr1d_op2[0]) || (vt1.m_vt_op1 / (decimal)d_arr1d_op2[0] != vt1.m_vt_op1 / m_arr1d_op2[0]) || (vt1.m_vt_op1 / m_arr1d_op2[0] != vt1.m_vt_op1 / i_arr1d_op2[0]) || (vt1.m_vt_op1 / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 38 failed"); passed = false; } if ((vt1.m_vt_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / ui_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / l_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / l_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / ul_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / m_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / m_arr2d_op2[index[0, 1], index[1, 0]] != vt1.m_vt_op1 / i_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.m_vt_op1 / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 39 failed"); passed = false; } if ((vt1.m_vt_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.m_vt_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.m_vt_op1 / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 40 failed"); passed = false; } if ((m_arr1d_op1[1] / i_l_op2 != m_arr1d_op1[1] / ui_l_op2) || (m_arr1d_op1[1] / ui_l_op2 != m_arr1d_op1[1] / l_l_op2) || (m_arr1d_op1[1] / l_l_op2 != m_arr1d_op1[1] / ul_l_op2) || (m_arr1d_op1[1] / ul_l_op2 != m_arr1d_op1[1] / (decimal)f_l_op2) || (m_arr1d_op1[1] / (decimal)f_l_op2 != m_arr1d_op1[1] / (decimal)d_l_op2) || (m_arr1d_op1[1] / (decimal)d_l_op2 != m_arr1d_op1[1] / m_l_op2) || (m_arr1d_op1[1] / m_l_op2 != m_arr1d_op1[1] / i_l_op2) || (m_arr1d_op1[1] / i_l_op2 != 25)) { Console.WriteLine("testcase 41 failed"); passed = false; } if ((m_arr1d_op1[1] / s_i_s_op2 != m_arr1d_op1[1] / s_ui_s_op2) || (m_arr1d_op1[1] / s_ui_s_op2 != m_arr1d_op1[1] / s_l_s_op2) || (m_arr1d_op1[1] / s_l_s_op2 != m_arr1d_op1[1] / s_ul_s_op2) || (m_arr1d_op1[1] / s_ul_s_op2 != m_arr1d_op1[1] / (decimal)s_f_s_op2) || (m_arr1d_op1[1] / (decimal)s_f_s_op2 != m_arr1d_op1[1] / (decimal)s_d_s_op2) || (m_arr1d_op1[1] / (decimal)s_d_s_op2 != m_arr1d_op1[1] / s_m_s_op2) || (m_arr1d_op1[1] / s_m_s_op2 != m_arr1d_op1[1] / s_i_s_op2) || (m_arr1d_op1[1] / s_i_s_op2 != 25)) { Console.WriteLine("testcase 42 failed"); passed = false; } if ((m_arr1d_op1[1] / m_f("op2") != m_arr1d_op1[1] / m_f("op2")) || (m_arr1d_op1[1] / m_f("op2") != m_arr1d_op1[1] / m_f("op2")) || (m_arr1d_op1[1] / m_f("op2") != m_arr1d_op1[1] / m_f("op2")) || (m_arr1d_op1[1] / m_f("op2") != m_arr1d_op1[1] / (decimal)m_f("op2")) || (m_arr1d_op1[1] / (decimal)m_f("op2") != m_arr1d_op1[1] / (decimal)m_f("op2")) || (m_arr1d_op1[1] / (decimal)m_f("op2") != m_arr1d_op1[1] / m_f("op2")) || (m_arr1d_op1[1] / m_f("op2") != m_arr1d_op1[1] / m_f("op2")) || (m_arr1d_op1[1] / m_f("op2") != 25)) { Console.WriteLine("testcase 43 failed"); passed = false; } if ((m_arr1d_op1[1] / cl1.i_cl_op2 != m_arr1d_op1[1] / cl1.ui_cl_op2) || (m_arr1d_op1[1] / cl1.ui_cl_op2 != m_arr1d_op1[1] / cl1.l_cl_op2) || (m_arr1d_op1[1] / cl1.l_cl_op2 != m_arr1d_op1[1] / cl1.ul_cl_op2) || (m_arr1d_op1[1] / cl1.ul_cl_op2 != m_arr1d_op1[1] / (decimal)cl1.f_cl_op2) || (m_arr1d_op1[1] / (decimal)cl1.f_cl_op2 != m_arr1d_op1[1] / (decimal)cl1.d_cl_op2) || (m_arr1d_op1[1] / (decimal)cl1.d_cl_op2 != m_arr1d_op1[1] / cl1.m_cl_op2) || (m_arr1d_op1[1] / cl1.m_cl_op2 != m_arr1d_op1[1] / cl1.i_cl_op2) || (m_arr1d_op1[1] / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 44 failed"); passed = false; } if ((m_arr1d_op1[1] / vt1.i_vt_op2 != m_arr1d_op1[1] / vt1.ui_vt_op2) || (m_arr1d_op1[1] / vt1.ui_vt_op2 != m_arr1d_op1[1] / vt1.l_vt_op2) || (m_arr1d_op1[1] / vt1.l_vt_op2 != m_arr1d_op1[1] / vt1.ul_vt_op2) || (m_arr1d_op1[1] / vt1.ul_vt_op2 != m_arr1d_op1[1] / (decimal)vt1.f_vt_op2) || (m_arr1d_op1[1] / (decimal)vt1.f_vt_op2 != m_arr1d_op1[1] / (decimal)vt1.d_vt_op2) || (m_arr1d_op1[1] / (decimal)vt1.d_vt_op2 != m_arr1d_op1[1] / vt1.m_vt_op2) || (m_arr1d_op1[1] / vt1.m_vt_op2 != m_arr1d_op1[1] / vt1.i_vt_op2) || (m_arr1d_op1[1] / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 45 failed"); passed = false; } if ((m_arr1d_op1[1] / i_arr1d_op2[0] != m_arr1d_op1[1] / ui_arr1d_op2[0]) || (m_arr1d_op1[1] / ui_arr1d_op2[0] != m_arr1d_op1[1] / l_arr1d_op2[0]) || (m_arr1d_op1[1] / l_arr1d_op2[0] != m_arr1d_op1[1] / ul_arr1d_op2[0]) || (m_arr1d_op1[1] / ul_arr1d_op2[0] != m_arr1d_op1[1] / (decimal)f_arr1d_op2[0]) || (m_arr1d_op1[1] / (decimal)f_arr1d_op2[0] != m_arr1d_op1[1] / (decimal)d_arr1d_op2[0]) || (m_arr1d_op1[1] / (decimal)d_arr1d_op2[0] != m_arr1d_op1[1] / m_arr1d_op2[0]) || (m_arr1d_op1[1] / m_arr1d_op2[0] != m_arr1d_op1[1] / i_arr1d_op2[0]) || (m_arr1d_op1[1] / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 46 failed"); passed = false; } if ((m_arr1d_op1[1] / i_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / ui_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / l_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / l_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / ul_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / m_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / m_arr2d_op2[index[0, 1], index[1, 0]] != m_arr1d_op1[1] / i_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr1d_op1[1] / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 47 failed"); passed = false; } if ((m_arr1d_op1[1] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr1d_op1[1] / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr1d_op1[1] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 48 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / i_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / ui_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ui_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / l_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / l_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / ul_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ul_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / m_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_l_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / i_l_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / i_l_op2 != 25)) { Console.WriteLine("testcase 49 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / s_i_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / s_ui_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / s_ui_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / s_l_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / s_l_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / s_ul_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / s_ul_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)s_f_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)s_f_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)s_d_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)s_d_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / s_m_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / s_m_s_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / s_i_s_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / s_i_s_op2 != 25)) { Console.WriteLine("testcase 50 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2")) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_f("op2") != 25)) { Console.WriteLine("testcase 51 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.i_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.ui_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.ui_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.l_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.l_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.ul_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.ul_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)cl1.f_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)cl1.f_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)cl1.d_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)cl1.d_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.m_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.m_cl_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.i_cl_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 52 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.i_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.ui_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.ui_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.l_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.l_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.ul_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.ul_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)vt1.f_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)vt1.f_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)vt1.d_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)vt1.d_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.m_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.m_vt_op2 != m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.i_vt_op2) || (m_arr2d_op1[index[0, 1], index[1, 0]] / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 53 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr1d_op2[0] != m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr1d_op2[0]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 54 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr2d_op2[index[0, 1], index[1, 0]] != m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 55 failed"); passed = false; } if ((m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr2d_op1[index[0, 1], index[1, 0]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 56 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_l_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_l_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_l_op2 != 25)) { Console.WriteLine("testcase 57 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_i_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_ui_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_ui_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_l_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_l_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_ul_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_ul_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)s_f_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)s_f_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)s_d_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)s_d_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_m_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_m_s_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_i_s_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / s_i_s_op2 != 25)) { Console.WriteLine("testcase 58 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2")) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_f("op2") != 25)) { Console.WriteLine("testcase 59 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.i_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.ui_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.ui_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.l_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.l_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.ul_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.ul_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)cl1.f_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)cl1.f_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)cl1.d_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)cl1.d_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.m_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.m_cl_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.i_cl_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / cl1.i_cl_op2 != 25)) { Console.WriteLine("testcase 60 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.i_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.ui_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.ui_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.l_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.l_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.ul_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.ul_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)vt1.f_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)vt1.f_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)vt1.d_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)vt1.d_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.m_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.m_vt_op2 != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.i_vt_op2) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / vt1.i_vt_op2 != 25)) { Console.WriteLine("testcase 61 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr1d_op2[0] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr1d_op2[0]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr1d_op2[0] != 25)) { Console.WriteLine("testcase 62 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr2d_op2[index[0, 1], index[1, 0]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr2d_op2[index[0, 1], index[1, 0]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr2d_op2[index[0, 1], index[1, 0]] != 25)) { Console.WriteLine("testcase 63 failed"); passed = false; } if ((m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / l_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)f_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / (decimal)d_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / m_arr3d_op2[index[0, 0], 0, index[1, 1]] != m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (m_arr3d_op1[index[0, 0], 0, index[1, 1]] / i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 25)) { Console.WriteLine("testcase 64 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.ulong2darr = new ulong[,] { { 0, 1 }, { 0, 0 } }; vt1.ulong3darr = new ulong[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; vt1.ulong2darr_b = new ulong[,] { { 0, 49 }, { 0, 0 } }; vt1.ulong3darr_b = new ulong[,,] { { { 0, 0 } }, { { 0, 49 } }, { { 0, 0 } } }; CL cl1 = new CL(); ja1[0] = new ulong[,] { { 0, 1 }, { 0, 0 } }; ja2[1] = new ulong[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; ja1_b[0] = new ulong[,] { { 0, 49 }, { 0, 0 } }; ja2_b[1] = new ulong[,,] { { { 0, 0 } }, { { 0, 49 } }, { { 0, 0 } } }; ulong result = 1; // 2D if (result != ulong2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.ulong2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.ulong2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != ulong3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.ulong3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.ulong3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToBool bool Bool_result = true; // 2D if (Bool_result != Convert.ToBoolean(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Bool_result != Convert.ToBoolean(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToByte byte Byte_result = 1; // 2D if (Byte_result != Convert.ToByte(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Byte_result != Convert.ToByte(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToChar char Char_result = '1'; // 2D if (Char_result != Convert.ToChar(ulong2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(vt1.ulong2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("vt1.ulong2darr_b[0, 1] is: {0}", vt1.ulong2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(cl1.ulong2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("cl1.ulong2darr_b[0, 1] is: {0}", cl1.ulong2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Char_result != Convert.ToChar(ulong3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("ulong3darr_b[1,0,1] is: {0}", ulong3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(vt1.ulong3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("vt1.ulong3darr_b[1,0,1] is: {0}", vt1.ulong3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(cl1.ulong3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("cl1.ulong3darr_b[1,0,1] is: {0}", cl1.ulong3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Char_result != Convert.ToChar(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Char_result is: {0}", Char_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToDecimal decimal Decimal_result = 1; // 2D if (Decimal_result != Convert.ToDecimal(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Decimal_result != Convert.ToDecimal(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToDouble double Double_result = 1; // 2D if (Double_result != Convert.ToDouble(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Double_result != Convert.ToDouble(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToSingle float Single_result = 1; // 2D if (Single_result != Convert.ToSingle(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Single_result != Convert.ToSingle(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToInt32 int Int32_result = 1; // 2D if (Int32_result != Convert.ToInt32(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToInt64 long Int64_result = 1; // 2D if (Int64_result != Convert.ToInt64(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int64_result != Convert.ToInt64(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToSByte sbyte SByte_result = 1; // 2D if (SByte_result != Convert.ToSByte(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (SByte_result != Convert.ToSByte(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } short Int16_result = 1; // 2D if (Int16_result != Convert.ToInt16(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToUInt32 uint UInt32_result = 1; // 2D if (UInt32_result != Convert.ToUInt32(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //UInt64ToUInt16 ushort UInt16_result = 1; // 2D if (UInt16_result != Convert.ToUInt16(ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0, 1] is: {0}", ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.ulong2darr[0, 1] is: {0}", vt1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.ulong2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.ulong2darr[0, 1] is: {0}", cl1.ulong2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ulong3darr[1,0,1] is: {0}", ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.ulong3darr[1,0,1] is: {0}", vt1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.ulong3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.ulong3darr[1,0,1] is: {0}", cl1.ulong3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool passed = true; int* p = stackalloc int[11]; for (int m = 0; m < 11; m++) p[m] = m; String str2 = "test string"; String[] str1darr = { "string access", "test string" }; Char[,] c2darr = { { '0', '1', '2', '3', '4', '5', '6' }, { 'a', 'b', 'c', 'd', 'e', 'f', 'g' } }; CL cl1 = new CL(); VT vt1; vt1.i = 0; vt1.str = "test string"; vt1.idxja = new int[2][]; vt1.idxja[1] = new int[] { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; int idx2 = 4; int[] idx1darr = { 3, 9, 4, 2, 6, 1, 8, 10, 5, 7, 0 }; char b0, b1, b2, b3, b4, b5, b6; //accessing the strings at different indices. assign to local char b0 = str2[vt1.i]; b1 = str1[vt1.i]; b2 = cl1.str[vt1.i]; b3 = vt1.str[vt1.i]; b4 = str1darr[1][vt1.i]; b5 = str2darr[0, 0][vt1.i]; b6 = f(ref str2)[vt1.i]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; if ((str2[idx2] != str1[idx2]) || (str1[idx2] != cl1.str[idx2]) || (cl1.str[idx2] != vt1.str[idx2]) || (vt1.str[idx2] != str1darr[1][idx2]) || (str1darr[1][idx2] != str2darr[0, 0][idx2]) || (str2darr[0, 0][idx2] != f(ref str2)[idx2])) passed = false; b0 = str2[CL.i]; b1 = str1[CL.i]; b2 = cl1.str[CL.i]; b3 = vt1.str[CL.i]; b4 = str1darr[1][CL.i]; b5 = str2darr[0, 0][CL.i]; b6 = f(ref str2)[CL.i]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; int j = rand.Next(0, 10); b0 = str2[idx1darr[j]]; b1 = str1[idx1darr[j]]; b2 = cl1.str[idx1darr[j]]; b3 = vt1.str[idx1darr[j]]; b4 = str1darr[1][idx1darr[j]]; b5 = str2darr[0, 0][idx1darr[j]]; b6 = f(ref str2)[idx1darr[j]]; if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4) || (b4 != b5) || (b5 != b6)) passed = false; //accessing the strings at different indices, assign to static char sb0 = str2[idx1 - 1]; sb1 = str1[idx1 - 1]; sb2 = cl1.str[idx1 - 1]; sb3 = vt1.str[idx1 - 1]; sb4 = str1darr[idx1 - 1][idx1 - 1]; sb5 = str2darr[0, 0][idx1 - 1]; sb6 = f(ref str2)[idx1 - 1]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6) || (sb6 != str2[1])) passed = false; if ((str2[5] != str1[5]) || (str1[5] != cl1.str[5]) || (cl1.str[5] != vt1.str[5]) || (vt1.str[5] != str1darr[1][5]) || (str1darr[1][5] != str2darr[0, 0][5]) || (str2darr[0, 0][5] != f(ref str2)[5])) passed = false; sb0 = str2[idx3darr[0, 0, 0] + 1]; sb1 = str1[idx3darr[0, 0, 0] + 1]; sb2 = cl1.str[idx3darr[0, 0, 0] + 1]; sb3 = vt1.str[idx3darr[0, 0, 0] + 1]; sb4 = str1darr[1][idx3darr[0, 0, 0] + 1]; sb5 = str2darr[0, 0][idx3darr[0, 0, 0] + 1]; sb6 = f(ref str2)[idx3darr[0, 0, 0] + 1]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6)) passed = false; j = rand.Next(0, 10); sb0 = str2[vt1.idxja[1][j]]; sb1 = str1[vt1.idxja[1][j]]; sb2 = cl1.str[vt1.idxja[1][j]]; sb3 = vt1.str[vt1.idxja[1][j]]; sb4 = str1darr[1][vt1.idxja[1][j]]; sb5 = str2darr[0, 0][vt1.idxja[1][j]]; sb6 = f(ref str2)[vt1.idxja[1][j]]; if ((sb0 != sb1) || (sb1 != sb2) || (sb2 != sb3) || (sb3 != sb4) || (sb4 != sb5) || (sb5 != sb6)) passed = false; //accessing the strings at different indices, assign to VT char vt1.b0 = str2[idx2 - idx1]; vt1.b1 = str1[idx2 - idx1]; vt1.b2 = cl1.str[idx2 - idx1]; vt1.b3 = vt1.str[idx2 - idx1]; vt1.b4 = str1darr[1][idx2 - idx1]; vt1.b5 = str2darr[0, 0][idx2 - idx1]; vt1.b6 = f(ref str2)[idx2 - idx1]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; if ((str2[cl1.idx2darr[0, 1]] != str1[cl1.idx2darr[0, 1]]) || (str1[cl1.idx2darr[0, 1]] != cl1.str[cl1.idx2darr[0, 1]]) || (cl1.str[cl1.idx2darr[0, 1]] != vt1.str[cl1.idx2darr[0, 1]]) || (vt1.str[cl1.idx2darr[0, 1]] != str1darr[1][cl1.idx2darr[0, 1]]) || (str1darr[1][cl1.idx2darr[0, 1]] != str2darr[0, 0][cl1.idx2darr[0, 1]]) || (str2darr[0, 0][cl1.idx2darr[0, 1]] != f(ref str2)[cl1.idx2darr[0, 1]])) passed = false; vt1.b0 = str2[idx3darr[0, 0, 0]]; vt1.b1 = str1[idx3darr[0, 0, 0]]; vt1.b2 = cl1.str[idx3darr[0, 0, 0]]; vt1.b3 = vt1.str[idx3darr[0, 0, 0]]; vt1.b4 = str1darr[1][idx3darr[0, 0, 0]]; vt1.b5 = str2darr[0, 0][idx3darr[0, 0, 0]]; vt1.b6 = f(ref str2)[idx3darr[0, 0, 0]]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; j = rand.Next(0, 10); vt1.b0 = str2[p[j]]; vt1.b1 = str1[p[j]]; vt1.b2 = cl1.str[p[j]]; vt1.b3 = vt1.str[p[j]]; vt1.b4 = str1darr[1][p[j]]; vt1.b5 = str2darr[0, 0][p[j]]; vt1.b6 = f(ref str2)[p[j]]; if ((vt1.b0 != vt1.b1) || (vt1.b1 != vt1.b2) || (vt1.b2 != vt1.b3) || (vt1.b3 != vt1.b4) || (vt1.b4 != vt1.b5) || (vt1.b5 != vt1.b6)) passed = false; //accessing the strings at different indices, assign to CL char cl1.b0 = str2[CL.i % idx1darr[0]]; cl1.b1 = str1[CL.i % idx1darr[0]]; cl1.b2 = cl1.str[CL.i % idx1darr[0]]; cl1.b3 = vt1.str[CL.i % idx1darr[0]]; cl1.b4 = str1darr[1][CL.i % idx1darr[0]]; cl1.b5 = str2darr[0, 0][CL.i % idx1darr[0]]; cl1.b6 = f(ref str2)[CL.i % idx1darr[0]]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6)) passed = false; if ((str2[0] != str1[0]) || (str1[0] != cl1.str[0]) || (cl1.str[0] != vt1.str[0]) || (vt1.str[0] != str1darr[1][0]) || (str1darr[1][0] != str2darr[0, 0][0]) || (str2darr[0, 0][0] != f(ref str2)[0])) passed = false; cl1.b0 = str2[Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b1 = str1[Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b2 = cl1.str[Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b3 = vt1.str[Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b4 = str1darr[1][Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b5 = str2darr[0, 0][Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; cl1.b6 = f(ref str2)[Convert.ToInt32(c2darr[0, 4]) - Convert.ToInt32(c2darr[0, 0])]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6) || (cl1.b6 != str1[4])) passed = false; j = rand.Next(0, 10); cl1.b0 = str2[j]; cl1.b1 = str1[j]; cl1.b2 = cl1.str[j]; cl1.b3 = vt1.str[j]; cl1.b4 = str1darr[1][j]; cl1.b5 = str2darr[0, 0][j]; cl1.b6 = f(ref str2)[j]; if ((cl1.b0 != cl1.b1) || (cl1.b1 != cl1.b2) || (cl1.b2 != cl1.b3) || (cl1.b3 != cl1.b4) || (cl1.b4 != cl1.b5) || (cl1.b5 != cl1.b6)) passed = false; //accessing the strings at different indices, assign to 2d array char c2darr[1, 0] = str2[idx1darr[0] * idx1]; c2darr[1, 1] = str1[idx1darr[0] * idx1]; c2darr[1, 2] = cl1.str[idx1darr[0] * idx1]; c2darr[1, 3] = vt1.str[idx1darr[0] * idx1]; c2darr[1, 4] = str1darr[1][idx1darr[0] * idx1]; c2darr[1, 5] = str2darr[0, 0][idx1darr[0] * idx1]; c2darr[1, 6] = f(ref str2)[idx1darr[0] * idx1]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6]) || (str2[6] != c2darr[1, 6])) passed = false; if ((str2[vt1.i] != str1[vt1.i]) || (str1[vt1.i] != cl1.str[vt1.i]) || (cl1.str[vt1.i] != vt1.str[vt1.i]) || (vt1.str[vt1.i] != str1darr[1][vt1.i]) || (str1darr[1][vt1.i] != str2darr[0, 0][vt1.i]) || (str2darr[0, 0][vt1.i] != f(ref str2)[vt1.i])) passed = false; c2darr[1, 0] = str2[idx1darr[1] - idx1darr[0]]; c2darr[1, 1] = str1[idx1darr[1] - idx1darr[0]]; c2darr[1, 2] = cl1.str[idx1darr[1] - idx1darr[0]]; c2darr[1, 3] = vt1.str[idx1darr[1] - idx1darr[0]]; c2darr[1, 4] = str1darr[1][idx1darr[1] - idx1darr[0]]; c2darr[1, 5] = str2darr[0, 0][idx1darr[1] - idx1darr[0]]; c2darr[1, 6] = f(ref str2)[idx1darr[1] - idx1darr[0]]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6]) || (str2[6] != c2darr[1, 6])) passed = false; j = rand.Next(0, 10); c2darr[1, 0] = str2[f1(ref j)]; c2darr[1, 1] = str1[f1(ref j)]; c2darr[1, 2] = cl1.str[f1(ref j)]; c2darr[1, 3] = vt1.str[f1(ref j)]; c2darr[1, 4] = str1darr[1][f1(ref j)]; c2darr[1, 5] = str2darr[0, 0][f1(ref j)]; c2darr[1, 6] = f(ref str2)[f1(ref j)]; if ((c2darr[1, 0] != c2darr[1, 1]) || (c2darr[1, 1] != c2darr[1, 2]) || (c2darr[1, 2] != c2darr[1, 3]) || (c2darr[1, 3] != c2darr[1, 4]) || (c2darr[1, 4] != c2darr[1, 5]) || (c2darr[1, 5] != c2darr[1, 6])) passed = false; if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.char2darr = new char[,] { { '0', '1' }, { '0', '0' } }; vt1.char3darr = new char[,,] { { { '0', '0' } }, { { '0', '1' } }, { { '0', '0' } } }; CL cl1 = new CL(); ja1[0] = new char[,] { { '0', '1' }, { '0', '0' } }; ja2[1] = new char[,,] { { { '0', '0' } }, { { '0', '1' } }, { { '0', '0' } } }; char result = '1'; // 2D if (result != char2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.char2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.char2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != char3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.char3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.char3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToByte tests byte Byte_result = 49; // 2D if (Byte_result != Convert.ToByte(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Byte_result != Convert.ToByte(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToInt32 tests int Int32_result = 49; // 2D if (Int32_result != Convert.ToInt32(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToInt64 tests long Int64_result = 49; // 2D if (Int64_result != Convert.ToInt64(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int64_result != Convert.ToInt64(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToSByte tests sbyte SByte_result = 49; // 2D if (SByte_result != Convert.ToSByte(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (SByte_result != Convert.ToSByte(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToInt16 tests short Int16_result = 49; // 2D if (Int16_result != Convert.ToInt16(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToUInt32 uint UInt32_result = 49; // 2D if (UInt32_result != Convert.ToUInt32(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToUInt64 ulong UInt64_result = 49; // 2D if (UInt64_result != Convert.ToUInt64(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt64_result != Convert.ToUInt64(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //CharToUInt16 tests ushort UInt16_result = 49; // 2D if (UInt16_result != Convert.ToUInt16(char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0,1] is: {0}", char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.char2darr[0,1] is: {0}", vt1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.char2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.char2darr[0,1] is: {0}", cl1.char2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1[0][0,1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("char3darr[1,0,1] is: {0}", char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.char3darr[1,0,1] is: {0}", vt1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.char3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.char3darr[1,0,1] is: {0}", cl1.char3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.d_vt_test1_op1 = Double.NaN; vt1.d_vt_test1_op2 = 0; vt1.d_vt_test2_op1 = Double.NaN; vt1.d_vt_test2_op2 = Double.NegativeInfinity; vt1.d_vt_test3_op1 = Double.PositiveInfinity; vt1.d_vt_test3_op2 = Double.PositiveInfinity; double[] d_arr1d_test1_op1 = { 0, Double.NaN }; double[,] d_arr2d_test1_op1 = { { 0, Double.NaN }, { 1, 1 } }; double[, ,] d_arr3d_test1_op1 = { { { 0, Double.NaN }, { 1, 1 } } }; double[] d_arr1d_test1_op2 = { 0, 0, 1 }; double[,] d_arr2d_test1_op2 = { { 0, 0 }, { 1, 1 } }; double[, ,] d_arr3d_test1_op2 = { { { 0, 0 }, { 1, 1 } } }; double[] d_arr1d_test2_op1 = { 0, Double.NaN }; double[,] d_arr2d_test2_op1 = { { 0, Double.NaN }, { 1, 1 } }; double[, ,] d_arr3d_test2_op1 = { { { 0, Double.NaN }, { 1, 1 } } }; double[] d_arr1d_test2_op2 = { Double.NegativeInfinity, 0, 1 }; double[,] d_arr2d_test2_op2 = { { 0, Double.NegativeInfinity }, { 1, 1 } }; double[, ,] d_arr3d_test2_op2 = { { { 0, Double.NegativeInfinity }, { 1, 1 } } }; double[] d_arr1d_test3_op1 = { 0, Double.PositiveInfinity }; double[,] d_arr2d_test3_op1 = { { 0, Double.PositiveInfinity }, { 1, 1 } }; double[, ,] d_arr3d_test3_op1 = { { { 0, Double.PositiveInfinity }, { 1, 1 } } }; double[] d_arr1d_test3_op2 = { Double.PositiveInfinity, 0, 1 }; double[,] d_arr2d_test3_op2 = { { 0, Double.PositiveInfinity }, { 1, 1 } }; double[, ,] d_arr3d_test3_op2 = { { { 0, Double.PositiveInfinity }, { 1, 1 } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { double d_l_test1_op1 = Double.NaN; double d_l_test1_op2 = 0; if (!Double.IsNaN(d_l_test1_op1 - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 1 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 2 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 3 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 4 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 5 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 6 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 7 failed"); passed = false; } if (!Double.IsNaN(d_l_test1_op1 - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 8 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 9 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 10 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 11 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 12 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 13 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 14 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 15 failed"); passed = false; } if (!Double.IsNaN(d_s_test1_op1 - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 16 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 17 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 18 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 19 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 20 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 21 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 22 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 23 failed"); passed = false; } if (!Double.IsNaN(d_test1_f("test1_op1") - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 24 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 25 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 26 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 27 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 28 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 29 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 30 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 31 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test1_op1 - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 32 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 33 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 34 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 35 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 36 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 37 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 38 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 39 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test1_op1 - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 40 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 41 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 42 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 43 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 44 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 45 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 46 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 47 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test1_op1[1] - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 48 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 49 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 50 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 51 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 52 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 53 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 54 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 55 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test1_op1[index[0, 1], index[1, 0]] - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 56 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_l_test1_op2)) { Console.WriteLine("Test1_testcase 57 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_s_test1_op2)) { Console.WriteLine("Test1_testcase 58 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 59 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - cl1.d_cl_test1_op2)) { Console.WriteLine("Test1_testcase 60 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - vt1.d_vt_test1_op2)) { Console.WriteLine("Test1_testcase 61 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 62 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 63 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] - d_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 64 failed"); passed = false; } } { double d_l_test2_op1 = Double.NaN; double d_l_test2_op2 = Double.NegativeInfinity; if (!Double.IsNaN(d_l_test2_op1 - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 1 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 2 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 3 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 4 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 5 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 6 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 7 failed"); passed = false; } if (!Double.IsNaN(d_l_test2_op1 - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 8 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 9 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 10 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 11 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 12 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 13 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 14 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 15 failed"); passed = false; } if (!Double.IsNaN(d_s_test2_op1 - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 16 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 17 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 18 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 19 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 20 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 21 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 22 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 23 failed"); passed = false; } if (!Double.IsNaN(d_test2_f("test2_op1") - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 24 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 25 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 26 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 27 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 28 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 29 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 30 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 31 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test2_op1 - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 32 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 33 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 34 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 35 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 36 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 37 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 38 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 39 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test2_op1 - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 40 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 41 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 42 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 43 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 44 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 45 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 46 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 47 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test2_op1[1] - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 48 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 49 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 50 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 51 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 52 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 53 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 54 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 55 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test2_op1[index[0, 1], index[1, 0]] - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 56 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_l_test2_op2)) { Console.WriteLine("Test2_testcase 57 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_s_test2_op2)) { Console.WriteLine("Test2_testcase 58 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 59 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - cl1.d_cl_test2_op2)) { Console.WriteLine("Test2_testcase 60 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - vt1.d_vt_test2_op2)) { Console.WriteLine("Test2_testcase 61 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 62 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 63 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] - d_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 64 failed"); passed = false; } } { double d_l_test3_op1 = Double.PositiveInfinity; double d_l_test3_op2 = Double.PositiveInfinity; if (!Double.IsNaN(d_l_test3_op1 - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 1 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 2 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 3 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 4 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 5 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 6 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 7 failed"); passed = false; } if (!Double.IsNaN(d_l_test3_op1 - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 8 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 9 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 10 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 11 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 12 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 13 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 14 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 15 failed"); passed = false; } if (!Double.IsNaN(d_s_test3_op1 - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 16 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 17 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 18 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 19 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 20 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 21 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 22 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 23 failed"); passed = false; } if (!Double.IsNaN(d_test3_f("test3_op1") - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 24 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 25 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 26 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 27 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 28 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 29 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 30 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 31 failed"); passed = false; } if (!Double.IsNaN(cl1.d_cl_test3_op1 - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 32 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 33 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 34 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 35 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 36 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 37 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 38 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 39 failed"); passed = false; } if (!Double.IsNaN(vt1.d_vt_test3_op1 - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 40 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 41 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 42 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 43 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 44 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 45 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 46 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 47 failed"); passed = false; } if (!Double.IsNaN(d_arr1d_test3_op1[1] - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 48 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 49 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 50 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 51 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 52 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 53 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 54 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 55 failed"); passed = false; } if (!Double.IsNaN(d_arr2d_test3_op1[index[0, 1], index[1, 0]] - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 56 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_l_test3_op2)) { Console.WriteLine("Test3_testcase 57 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_s_test3_op2)) { Console.WriteLine("Test3_testcase 58 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 59 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - cl1.d_cl_test3_op2)) { Console.WriteLine("Test3_testcase 60 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - vt1.d_vt_test3_op2)) { Console.WriteLine("Test3_testcase 61 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 62 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 63 failed"); passed = false; } if (!Double.IsNaN(d_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] - d_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 64 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.f_vt_test1_op1 = Single.PositiveInfinity; vt1.f_vt_test1_op2 = 0; vt1.f_vt_test2_op1 = Single.NegativeInfinity; vt1.f_vt_test2_op2 = 0; vt1.f_vt_test3_op1 = 3; vt1.f_vt_test3_op2 = Single.NaN; float[] f_arr1d_test1_op1 = { 0, Single.PositiveInfinity }; float[,] f_arr2d_test1_op1 = { { 0, Single.PositiveInfinity }, { 1, 1 } }; float[, ,] f_arr3d_test1_op1 = { { { 0, Single.PositiveInfinity }, { 1, 1 } } }; float[] f_arr1d_test1_op2 = { 0, 0, 1 }; float[,] f_arr2d_test1_op2 = { { 0, 0 }, { 1, 1 } }; float[, ,] f_arr3d_test1_op2 = { { { 0, 0 }, { 1, 1 } } }; float[] f_arr1d_test2_op1 = { 0, Single.NegativeInfinity }; float[,] f_arr2d_test2_op1 = { { 0, Single.NegativeInfinity }, { 1, 1 } }; float[, ,] f_arr3d_test2_op1 = { { { 0, Single.NegativeInfinity }, { 1, 1 } } }; float[] f_arr1d_test2_op2 = { 0, 0, 1 }; float[,] f_arr2d_test2_op2 = { { 0, 0 }, { 1, 1 } }; float[, ,] f_arr3d_test2_op2 = { { { 0, 0 }, { 1, 1 } } }; float[] f_arr1d_test3_op1 = { 0, 3 }; float[,] f_arr2d_test3_op1 = { { 0, 3 }, { 1, 1 } }; float[, ,] f_arr3d_test3_op1 = { { { 0, 3 }, { 1, 1 } } }; float[] f_arr1d_test3_op2 = { Single.NaN, 0, 1 }; float[,] f_arr2d_test3_op2 = { { 0, Single.NaN }, { 1, 1 } }; float[, ,] f_arr3d_test3_op2 = { { { 0, Single.NaN }, { 1, 1 } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { float f_l_test1_op1 = Single.PositiveInfinity; float f_l_test1_op2 = 0; if (!Single.IsNaN(f_l_test1_op1 * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 1 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 2 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 3 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 4 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 5 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 6 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 7 failed"); passed = false; } if (!Single.IsNaN(f_l_test1_op1 * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 8 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 9 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 10 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 11 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 12 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 13 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 14 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 15 failed"); passed = false; } if (!Single.IsNaN(f_s_test1_op1 * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 16 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 17 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 18 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 19 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 20 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 21 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 22 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 23 failed"); passed = false; } if (!Single.IsNaN(f_test1_f("test1_op1") * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 24 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 25 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 26 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 27 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 28 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 29 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 30 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 31 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test1_op1 * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 32 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 33 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 34 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 35 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 36 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 37 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 38 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 39 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test1_op1 * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 40 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 41 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 42 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 43 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 44 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 45 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 46 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 47 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test1_op1[1] * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 48 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 49 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 50 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 51 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 52 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 53 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 54 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 55 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test1_op1[index[0, 1], index[1, 0]] * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 56 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_l_test1_op2)) { Console.WriteLine("Test1_testcase 57 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_s_test1_op2)) { Console.WriteLine("Test1_testcase 58 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_test1_f("test1_op2"))) { Console.WriteLine("Test1_testcase 59 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * cl1.f_cl_test1_op2)) { Console.WriteLine("Test1_testcase 60 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * vt1.f_vt_test1_op2)) { Console.WriteLine("Test1_testcase 61 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_arr1d_test1_op2[0])) { Console.WriteLine("Test1_testcase 62 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_arr2d_test1_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test1_testcase 63 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test1_op1[index[0, 0], 0, index[1, 1]] * f_arr3d_test1_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test1_testcase 64 failed"); passed = false; } } { float f_l_test2_op1 = Single.NegativeInfinity; float f_l_test2_op2 = 0; if (!Single.IsNaN(f_l_test2_op1 * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 1 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 2 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 3 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 4 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 5 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 6 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 7 failed"); passed = false; } if (!Single.IsNaN(f_l_test2_op1 * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 8 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 9 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 10 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 11 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 12 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 13 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 14 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 15 failed"); passed = false; } if (!Single.IsNaN(f_s_test2_op1 * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 16 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 17 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 18 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 19 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 20 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 21 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 22 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 23 failed"); passed = false; } if (!Single.IsNaN(f_test2_f("test2_op1") * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 24 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 25 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 26 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 27 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 28 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 29 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 30 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 31 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test2_op1 * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 32 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 33 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 34 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 35 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 36 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 37 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 38 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 39 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test2_op1 * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 40 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 41 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 42 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 43 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 44 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 45 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 46 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 47 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test2_op1[1] * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 48 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 49 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 50 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 51 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 52 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 53 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 54 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 55 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test2_op1[index[0, 1], index[1, 0]] * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 56 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_l_test2_op2)) { Console.WriteLine("Test2_testcase 57 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_s_test2_op2)) { Console.WriteLine("Test2_testcase 58 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_test2_f("test2_op2"))) { Console.WriteLine("Test2_testcase 59 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * cl1.f_cl_test2_op2)) { Console.WriteLine("Test2_testcase 60 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * vt1.f_vt_test2_op2)) { Console.WriteLine("Test2_testcase 61 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_arr1d_test2_op2[0])) { Console.WriteLine("Test2_testcase 62 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_arr2d_test2_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test2_testcase 63 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test2_op1[index[0, 0], 0, index[1, 1]] * f_arr3d_test2_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test2_testcase 64 failed"); passed = false; } } { float f_l_test3_op1 = 3; float f_l_test3_op2 = Single.NaN; if (!Single.IsNaN(f_l_test3_op1 * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 1 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 2 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 3 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 4 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 5 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 6 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 7 failed"); passed = false; } if (!Single.IsNaN(f_l_test3_op1 * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 8 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 9 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 10 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 11 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 12 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 13 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 14 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 15 failed"); passed = false; } if (!Single.IsNaN(f_s_test3_op1 * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 16 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 17 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 18 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 19 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 20 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 21 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 22 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 23 failed"); passed = false; } if (!Single.IsNaN(f_test3_f("test3_op1") * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 24 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 25 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 26 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 27 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 28 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 29 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 30 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 31 failed"); passed = false; } if (!Single.IsNaN(cl1.f_cl_test3_op1 * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 32 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 33 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 34 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 35 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 36 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 37 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 38 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 39 failed"); passed = false; } if (!Single.IsNaN(vt1.f_vt_test3_op1 * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 40 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 41 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 42 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 43 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 44 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 45 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 46 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 47 failed"); passed = false; } if (!Single.IsNaN(f_arr1d_test3_op1[1] * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 48 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 49 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 50 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 51 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 52 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 53 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 54 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 55 failed"); passed = false; } if (!Single.IsNaN(f_arr2d_test3_op1[index[0, 1], index[1, 0]] * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 56 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_l_test3_op2)) { Console.WriteLine("Test3_testcase 57 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_s_test3_op2)) { Console.WriteLine("Test3_testcase 58 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_test3_f("test3_op2"))) { Console.WriteLine("Test3_testcase 59 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * cl1.f_cl_test3_op2)) { Console.WriteLine("Test3_testcase 60 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * vt1.f_vt_test3_op2)) { Console.WriteLine("Test3_testcase 61 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_arr1d_test3_op2[0])) { Console.WriteLine("Test3_testcase 62 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_arr2d_test3_op2[index[0, 1], index[1, 0]])) { Console.WriteLine("Test3_testcase 63 failed"); passed = false; } if (!Single.IsNaN(f_arr3d_test3_op1[index[0, 0], 0, index[1, 1]] * f_arr3d_test3_op2[index[0, 0], 0, index[1, 1]])) { Console.WriteLine("Test3_testcase 64 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.float2darr = new float[,] { { 0, -1 }, { 0, 0 } }; vt1.float3darr = new float[,,] { { { 0, 0 } }, { { 0, -1 } }, { { 0, 0 } } }; vt1.float2darr_b = new float[,] { { 0, 1 }, { 0, 0 } }; vt1.float3darr_b = new float[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; CL cl1 = new CL(); ja1[0] = new float[,] { { 0, -1 }, { 0, 0 } }; ja2[1] = new float[,,] { { { 0, 0 } }, { { 0, -1 } }, { { 0, 0 } } }; ja1_b[0] = new float[,] { { 0, 1 }, { 0, 0 } }; ja2_b[1] = new float[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; float result = -1; // 2D if (result != float2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.float2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.float2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != float3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.float3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.float3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToBool bool Bool_result = true; // 2D if (Bool_result != Convert.ToBoolean(float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.float2darr_b[0, 1] is: {0}", vt1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.float2darr_b[0, 1] is: {0}", cl1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Bool_result != Convert.ToBoolean(float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("float3darr_b[1,0,1] is: {0}", float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(vt1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("vt1.float3darr_b[1,0,1] is: {0}", vt1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(cl1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("cl1.float3darr_b[1,0,1] is: {0}", cl1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Bool_result != Convert.ToBoolean(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Bool_result is: {0}", Bool_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToByte tests byte Byte_result = 1; // 2D if (Byte_result != Convert.ToByte(float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.float2darr_b[0, 1] is: {0}", vt1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.float2darr_b[0, 1] is: {0}", cl1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Byte_result != Convert.ToByte(float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("float3darr_b[1,0,1] is: {0}", float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.float3darr_b[1,0,1] is: {0}", vt1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.float3darr_b[1,0,1] is: {0}", cl1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToDecimal tests decimal Decimal_result = -1; // 2D if (Decimal_result != Convert.ToDecimal(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Decimal_result != Convert.ToDecimal(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Decimal_result != Convert.ToDecimal(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Decimal_result is: {0}", Decimal_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToDouble tests double Double_result = -1; // 2D if (Double_result != Convert.ToDouble(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Double_result != Convert.ToDouble(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Double_result != Convert.ToDouble(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Double_result is: {0}", Double_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToInt32 tests int Int32_result = -1; // 2D if (Int32_result != Convert.ToInt32(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToInt64 tests long Int64_result = -1; // 2D if (Int64_result != Convert.ToInt64(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int64_result != Convert.ToInt64(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToSByte tests sbyte SByte_result = -1; // 2D if (SByte_result != Convert.ToSByte(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (SByte_result != Convert.ToSByte(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToInt16 tests short Int16_result = -1; // 2D if (Int16_result != Convert.ToInt16(float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.float2darr[0, 1] is: {0}", vt1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.float2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.float2darr[0, 1] is: {0}", cl1.float2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("float3darr[1,0,1] is: {0}", float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.float3darr[1,0,1] is: {0}", vt1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.float3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.float3darr[1,0,1] is: {0}", cl1.float3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToUInt32 tests uint UInt32_result = 1; // 2D if (UInt32_result != Convert.ToUInt32(float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.float2darr_b[0, 1] is: {0}", vt1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.float2darr_b[0, 1] is: {0}", cl1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("float3darr_b[1,0,1] is: {0}", float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.float3darr_b[1,0,1] is: {0}", vt1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.float3darr_b[1,0,1] is: {0}", cl1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToUInt64 tests ulong UInt64_result = 1; // 2D if (UInt64_result != Convert.ToUInt64(float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.float2darr_b[0, 1] is: {0}", vt1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.float2darr_b[0, 1] is: {0}", cl1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt64_result != Convert.ToUInt64(float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("float3darr_b[1,0,1] is: {0}", float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.float3darr_b[1,0,1] is: {0}", vt1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.float3darr_b[1,0,1] is: {0}", cl1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //SingleToUInt16 tests ushort UInt16_result = 1; // 2D if (UInt16_result != Convert.ToUInt16(float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0, 1] is: {0}", float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.float2darr_b[0, 1] is: {0}", vt1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.float2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.float2darr_b[0, 1] is: {0}", cl1.float2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("float3darr_b[1,0,1] is: {0}", float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.float3darr_b[1,0,1] is: {0}", vt1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.float3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.float3darr_b[1,0,1] is: {0}", cl1.float3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.bool2darr = new bool[,] { { false, true }, { false, false } }; vt1.bool3darr = new bool[,,] { { { false, false } }, { { false, true } }, { { false, false } } }; CL cl1 = new CL(); ja1[0] = new bool[,] { { false, true }, { false, false } }; ja2[1] = new bool[,,] { { { false, false } }, { { false, true } }, { { false, false } } }; bool result = true; // 2D if (result != bool2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.bool2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.bool2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != bool3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.bool3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.bool3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToByte tests byte byte_result = 1; // 2D if (byte_result != Convert.ToByte(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (byte_result != Convert.ToByte(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (byte_result != Convert.ToByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("byte_result is: {0}", byte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToInt32 tests int Int32_result = 1; // 2D if (Int32_result != Convert.ToInt32(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToLong tests long long_result = 1; // 2D if (long_result != Convert.ToInt64(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (long_result != Convert.ToInt64(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (long_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("long_result is: {0}", long_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToSbyte tests sbyte sbyte_result = 1; // 2D if (sbyte_result != Convert.ToSByte(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("sbyte_result is: {0}", sbyte_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (sbyte_result != Convert.ToSByte(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("sbyte_result is: {0}", sbyte_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (sbyte_result != Convert.ToSByte(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("sbyte_result is: {0}", sbyte_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (sbyte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("sbyte_result is: {0}", sbyte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (sbyte_result != Convert.ToSByte(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("sbyte_result is: {0}", sbyte_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToInt16 tests short Int16_result = 1; // 2D if (Int16_result != Convert.ToInt16(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToUInt32 tests uint UInt32_result = 1; // 2D if (UInt32_result != Convert.ToUInt32(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToUInt64 tests ulong UInt64_result = 1; // 2D if (UInt64_result != Convert.ToUInt64(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt64_result != Convert.ToUInt64(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //BoolToUInt16 tests ushort UInt16_result = 1; // 2D if (UInt16_result != Convert.ToUInt16(bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0, 1] is: {0}", bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.bool2darr[0, 1] is: {0}", vt1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.bool2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.bool2darr[0, 1] is: {0}", cl1.bool2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("bool3darr[1,0,1] is: {0}", bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.bool3darr[1,0,1] is: {0}", vt1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.bool3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.bool3darr[1,0,1] is: {0}", cl1.bool3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static void f5() { CL cl = new CL(); if (GC.GetGeneration(cl.cl_arr) != s_LOH_GEN) { Console.WriteLine("Generation {0}", GC.GetGeneration(cl.cl_arr)); throw new Exception(); } }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.i_vt_op1 = 1; vt1.ui_vt_op1 = 1; vt1.l_vt_op1 = 1; vt1.ul_vt_op1 = 1; vt1.f_vt_op1 = 1; vt1.d_vt_op1 = 1; vt1.m_vt_op1 = 1; vt1.i_vt_op2 = 8; vt1.ui_vt_op2 = 8; vt1.l_vt_op2 = 8; vt1.ul_vt_op2 = 8; vt1.f_vt_op2 = 8; vt1.d_vt_op2 = 8; vt1.m_vt_op2 = 8; vt1.nHldr_vt_op2 = new numHolder(8); int[] i_arr1d_op1 = { 0, 1 }; int[,] i_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; int[,,] i_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; uint[] ui_arr1d_op1 = { 0, 1 }; uint[,] ui_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; uint[,,] ui_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; long[] l_arr1d_op1 = { 0, 1 }; long[,] l_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; long[,,] l_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; ulong[] ul_arr1d_op1 = { 0, 1 }; ulong[,] ul_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; ulong[,,] ul_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; float[] f_arr1d_op1 = { 0, 1 }; float[,] f_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; float[,,] f_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; double[] d_arr1d_op1 = { 0, 1 }; double[,] d_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; double[,,] d_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; decimal[] m_arr1d_op1 = { 0, 1 }; decimal[,] m_arr2d_op1 = { { 0, 1 }, { 1, 1 } }; decimal[,,] m_arr3d_op1 = { { { 0, 1 }, { 1, 1 } } }; int[] i_arr1d_op2 = { 8, 0, 1 }; int[,] i_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; int[,,] i_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; uint[] ui_arr1d_op2 = { 8, 0, 1 }; uint[,] ui_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; uint[,,] ui_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; long[] l_arr1d_op2 = { 8, 0, 1 }; long[,] l_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; long[,,] l_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; ulong[] ul_arr1d_op2 = { 8, 0, 1 }; ulong[,] ul_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; ulong[,,] ul_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; float[] f_arr1d_op2 = { 8, 0, 1 }; float[,] f_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; float[,,] f_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; double[] d_arr1d_op2 = { 8, 0, 1 }; double[,] d_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; double[,,] d_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; decimal[] m_arr1d_op2 = { 8, 0, 1 }; decimal[,] m_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; decimal[,,] m_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; numHolder[] nHldr_arr1d_op2 = { new numHolder(8), new numHolder(0), new numHolder(1) }; numHolder[,] nHldr_arr2d_op2 = { { new numHolder(0), new numHolder(8) }, { new numHolder(1), new numHolder(1) } }; numHolder[,,] nHldr_arr3d_op2 = { { { new numHolder(0), new numHolder(8) }, { new numHolder(1), new numHolder(1) } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { int i_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((i_l_op1 + i_l_op2 != i_l_op1 + ui_l_op2) || (i_l_op1 + ui_l_op2 != i_l_op1 + l_l_op2) || (i_l_op1 + l_l_op2 != i_l_op1 + (int)ul_l_op2) || (i_l_op1 + (int)ul_l_op2 != i_l_op1 + f_l_op2) || (i_l_op1 + f_l_op2 != i_l_op1 + d_l_op2) || ((decimal)(i_l_op1 + d_l_op2) != i_l_op1 + m_l_op2) || (i_l_op1 + m_l_op2 != i_l_op1 + i_l_op2) || (i_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 1 failed"); passed = false; } if ((i_l_op1 + s_i_s_op2 != i_l_op1 + s_ui_s_op2) || (i_l_op1 + s_ui_s_op2 != i_l_op1 + s_l_s_op2) || (i_l_op1 + s_l_s_op2 != i_l_op1 + (int)s_ul_s_op2) || (i_l_op1 + (int)s_ul_s_op2 != i_l_op1 + s_f_s_op2) || (i_l_op1 + s_f_s_op2 != i_l_op1 + s_d_s_op2) || ((decimal)(i_l_op1 + s_d_s_op2) != i_l_op1 + s_m_s_op2) || (i_l_op1 + s_m_s_op2 != i_l_op1 + s_i_s_op2) || (i_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 2 failed"); passed = false; } if ((s_i_s_op1 + i_l_op2 != s_i_s_op1 + ui_l_op2) || (s_i_s_op1 + ui_l_op2 != s_i_s_op1 + l_l_op2) || (s_i_s_op1 + l_l_op2 != s_i_s_op1 + (int)ul_l_op2) || (s_i_s_op1 + (int)ul_l_op2 != s_i_s_op1 + f_l_op2) || (s_i_s_op1 + f_l_op2 != s_i_s_op1 + d_l_op2) || ((decimal)(s_i_s_op1 + d_l_op2) != s_i_s_op1 + m_l_op2) || (s_i_s_op1 + m_l_op2 != s_i_s_op1 + i_l_op2) || (s_i_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 3 failed"); passed = false; } if ((s_i_s_op1 + s_i_s_op2 != s_i_s_op1 + s_ui_s_op2) || (s_i_s_op1 + s_ui_s_op2 != s_i_s_op1 + s_l_s_op2) || (s_i_s_op1 + s_l_s_op2 != s_i_s_op1 + (int)s_ul_s_op2) || (s_i_s_op1 + (int)s_ul_s_op2 != s_i_s_op1 + s_f_s_op2) || (s_i_s_op1 + s_f_s_op2 != s_i_s_op1 + s_d_s_op2) || ((decimal)(s_i_s_op1 + s_d_s_op2) != s_i_s_op1 + s_m_s_op2) || (s_i_s_op1 + s_m_s_op2 != s_i_s_op1 + s_i_s_op2) || (s_i_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 4 failed"); passed = false; } } { uint ui_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((ui_l_op1 + i_l_op2 != ui_l_op1 + ui_l_op2) || (ui_l_op1 + ui_l_op2 != ui_l_op1 + l_l_op2) || ((ulong)(ui_l_op1 + l_l_op2) != ui_l_op1 + ul_l_op2) || (ui_l_op1 + ul_l_op2 != ui_l_op1 + f_l_op2) || (ui_l_op1 + f_l_op2 != ui_l_op1 + d_l_op2) || ((decimal)(ui_l_op1 + d_l_op2) != ui_l_op1 + m_l_op2) || (ui_l_op1 + m_l_op2 != ui_l_op1 + i_l_op2) || (ui_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 5 failed"); passed = false; } if ((ui_l_op1 + s_i_s_op2 != ui_l_op1 + s_ui_s_op2) || (ui_l_op1 + s_ui_s_op2 != ui_l_op1 + s_l_s_op2) || ((ulong)(ui_l_op1 + s_l_s_op2) != ui_l_op1 + s_ul_s_op2) || (ui_l_op1 + s_ul_s_op2 != ui_l_op1 + s_f_s_op2) || (ui_l_op1 + s_f_s_op2 != ui_l_op1 + s_d_s_op2) || ((decimal)(ui_l_op1 + s_d_s_op2) != ui_l_op1 + s_m_s_op2) || (ui_l_op1 + s_m_s_op2 != ui_l_op1 + s_i_s_op2) || (ui_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 6 failed"); passed = false; } if ((s_ui_s_op1 + i_l_op2 != s_ui_s_op1 + ui_l_op2) || (s_ui_s_op1 + ui_l_op2 != s_ui_s_op1 + l_l_op2) || ((ulong)(s_ui_s_op1 + l_l_op2) != s_ui_s_op1 + ul_l_op2) || (s_ui_s_op1 + ul_l_op2 != s_ui_s_op1 + f_l_op2) || (s_ui_s_op1 + f_l_op2 != s_ui_s_op1 + d_l_op2) || ((decimal)(s_ui_s_op1 + d_l_op2) != s_ui_s_op1 + m_l_op2) || (s_ui_s_op1 + m_l_op2 != s_ui_s_op1 + i_l_op2) || (s_ui_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 7 failed"); passed = false; } if ((s_ui_s_op1 + s_i_s_op2 != s_ui_s_op1 + s_ui_s_op2) || (s_ui_s_op1 + s_ui_s_op2 != s_ui_s_op1 + s_l_s_op2) || ((ulong)(s_ui_s_op1 + s_l_s_op2) != s_ui_s_op1 + s_ul_s_op2) || (s_ui_s_op1 + s_ul_s_op2 != s_ui_s_op1 + s_f_s_op2) || (s_ui_s_op1 + s_f_s_op2 != s_ui_s_op1 + s_d_s_op2) || ((decimal)(s_ui_s_op1 + s_d_s_op2) != s_ui_s_op1 + s_m_s_op2) || (s_ui_s_op1 + s_m_s_op2 != s_ui_s_op1 + s_i_s_op2) || (s_ui_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 8 failed"); passed = false; } } { long l_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((l_l_op1 + i_l_op2 != l_l_op1 + ui_l_op2) || (l_l_op1 + ui_l_op2 != l_l_op1 + l_l_op2) || (l_l_op1 + l_l_op2 != l_l_op1 + (long)ul_l_op2) || (l_l_op1 + (long)ul_l_op2 != l_l_op1 + f_l_op2) || (l_l_op1 + f_l_op2 != l_l_op1 + d_l_op2) || ((decimal)(l_l_op1 + d_l_op2) != l_l_op1 + m_l_op2) || (l_l_op1 + m_l_op2 != l_l_op1 + i_l_op2) || (l_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 9 failed"); passed = false; } if ((l_l_op1 + s_i_s_op2 != l_l_op1 + s_ui_s_op2) || (l_l_op1 + s_ui_s_op2 != l_l_op1 + s_l_s_op2) || (l_l_op1 + s_l_s_op2 != l_l_op1 + (long)s_ul_s_op2) || (l_l_op1 + (long)s_ul_s_op2 != l_l_op1 + s_f_s_op2) || (l_l_op1 + s_f_s_op2 != l_l_op1 + s_d_s_op2) || ((decimal)(l_l_op1 + s_d_s_op2) != l_l_op1 + s_m_s_op2) || (l_l_op1 + s_m_s_op2 != l_l_op1 + s_i_s_op2) || (l_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 10 failed"); passed = false; } if ((s_l_s_op1 + i_l_op2 != s_l_s_op1 + ui_l_op2) || (s_l_s_op1 + ui_l_op2 != s_l_s_op1 + l_l_op2) || (s_l_s_op1 + l_l_op2 != s_l_s_op1 + (long)ul_l_op2) || (s_l_s_op1 + (long)ul_l_op2 != s_l_s_op1 + f_l_op2) || (s_l_s_op1 + f_l_op2 != s_l_s_op1 + d_l_op2) || ((decimal)(s_l_s_op1 + d_l_op2) != s_l_s_op1 + m_l_op2) || (s_l_s_op1 + m_l_op2 != s_l_s_op1 + i_l_op2) || (s_l_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 11 failed"); passed = false; } if ((s_l_s_op1 + s_i_s_op2 != s_l_s_op1 + s_ui_s_op2) || (s_l_s_op1 + s_ui_s_op2 != s_l_s_op1 + s_l_s_op2) || (s_l_s_op1 + s_l_s_op2 != s_l_s_op1 + (long)s_ul_s_op2) || (s_l_s_op1 + (long)s_ul_s_op2 != s_l_s_op1 + s_f_s_op2) || (s_l_s_op1 + s_f_s_op2 != s_l_s_op1 + s_d_s_op2) || ((decimal)(s_l_s_op1 + s_d_s_op2) != s_l_s_op1 + s_m_s_op2) || (s_l_s_op1 + s_m_s_op2 != s_l_s_op1 + s_i_s_op2) || (s_l_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 12 failed"); passed = false; } } { ulong ul_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((ul_l_op1 + (ulong)i_l_op2 != ul_l_op1 + ui_l_op2) || (ul_l_op1 + ui_l_op2 != ul_l_op1 + (ulong)l_l_op2) || (ul_l_op1 + (ulong)l_l_op2 != ul_l_op1 + ul_l_op2) || (ul_l_op1 + ul_l_op2 != ul_l_op1 + f_l_op2) || (ul_l_op1 + f_l_op2 != ul_l_op1 + d_l_op2) || ((decimal)(ul_l_op1 + d_l_op2) != ul_l_op1 + m_l_op2) || (ul_l_op1 + m_l_op2 != ul_l_op1 + (ulong)i_l_op2) || (ul_l_op1 + (ulong)i_l_op2 != 9)) { Console.WriteLine("testcase 13 failed"); passed = false; } if ((ul_l_op1 + (ulong)s_i_s_op2 != ul_l_op1 + s_ui_s_op2) || (ul_l_op1 + s_ui_s_op2 != ul_l_op1 + (ulong)s_l_s_op2) || (ul_l_op1 + (ulong)s_l_s_op2 != ul_l_op1 + s_ul_s_op2) || (ul_l_op1 + s_ul_s_op2 != ul_l_op1 + s_f_s_op2) || (ul_l_op1 + s_f_s_op2 != ul_l_op1 + s_d_s_op2) || ((decimal)(ul_l_op1 + s_d_s_op2) != ul_l_op1 + s_m_s_op2) || (ul_l_op1 + s_m_s_op2 != ul_l_op1 + (ulong)s_i_s_op2) || (ul_l_op1 + (ulong)s_i_s_op2 != 9)) { Console.WriteLine("testcase 14 failed"); passed = false; } if ((s_ul_s_op1 + (ulong)i_l_op2 != s_ul_s_op1 + ui_l_op2) || (s_ul_s_op1 + ui_l_op2 != s_ul_s_op1 + (ulong)l_l_op2) || (s_ul_s_op1 + (ulong)l_l_op2 != s_ul_s_op1 + ul_l_op2) || (s_ul_s_op1 + ul_l_op2 != s_ul_s_op1 + f_l_op2) || (s_ul_s_op1 + f_l_op2 != s_ul_s_op1 + d_l_op2) || ((decimal)(s_ul_s_op1 + d_l_op2) != s_ul_s_op1 + m_l_op2) || (s_ul_s_op1 + m_l_op2 != s_ul_s_op1 + (ulong)i_l_op2) || (s_ul_s_op1 + (ulong)i_l_op2 != 9)) { Console.WriteLine("testcase 15 failed"); passed = false; } if ((s_ul_s_op1 + (ulong)s_i_s_op2 != s_ul_s_op1 + s_ui_s_op2) || (s_ul_s_op1 + s_ui_s_op2 != s_ul_s_op1 + (ulong)s_l_s_op2) || (s_ul_s_op1 + (ulong)s_l_s_op2 != s_ul_s_op1 + s_ul_s_op2) || (s_ul_s_op1 + s_ul_s_op2 != s_ul_s_op1 + s_f_s_op2) || (s_ul_s_op1 + s_f_s_op2 != s_ul_s_op1 + s_d_s_op2) || ((decimal)(s_ul_s_op1 + s_d_s_op2) != s_ul_s_op1 + s_m_s_op2) || (s_ul_s_op1 + s_m_s_op2 != s_ul_s_op1 + (ulong)s_i_s_op2) || (s_ul_s_op1 + (ulong)s_i_s_op2 != 9)) { Console.WriteLine("testcase 16 failed"); passed = false; } } { float f_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((f_l_op1 + i_l_op2 != f_l_op1 + ui_l_op2) || (f_l_op1 + ui_l_op2 != f_l_op1 + l_l_op2) || (f_l_op1 + l_l_op2 != f_l_op1 + ul_l_op2) || (f_l_op1 + ul_l_op2 != f_l_op1 + f_l_op2) || (f_l_op1 + f_l_op2 != f_l_op1 + d_l_op2) || (f_l_op1 + d_l_op2 != f_l_op1 + (float)m_l_op2) || (f_l_op1 + (float)m_l_op2 != f_l_op1 + i_l_op2) || (f_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 17 failed"); passed = false; } if ((f_l_op1 + s_i_s_op2 != f_l_op1 + s_ui_s_op2) || (f_l_op1 + s_ui_s_op2 != f_l_op1 + s_l_s_op2) || (f_l_op1 + s_l_s_op2 != f_l_op1 + s_ul_s_op2) || (f_l_op1 + s_ul_s_op2 != f_l_op1 + s_f_s_op2) || (f_l_op1 + s_f_s_op2 != f_l_op1 + s_d_s_op2) || (f_l_op1 + s_d_s_op2 != f_l_op1 + (float)s_m_s_op2) || (f_l_op1 + (float)s_m_s_op2 != f_l_op1 + s_i_s_op2) || (f_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 18 failed"); passed = false; } if ((s_f_s_op1 + i_l_op2 != s_f_s_op1 + ui_l_op2) || (s_f_s_op1 + ui_l_op2 != s_f_s_op1 + l_l_op2) || (s_f_s_op1 + l_l_op2 != s_f_s_op1 + ul_l_op2) || (s_f_s_op1 + ul_l_op2 != s_f_s_op1 + f_l_op2) || (s_f_s_op1 + f_l_op2 != s_f_s_op1 + d_l_op2) || (s_f_s_op1 + d_l_op2 != s_f_s_op1 + (float)m_l_op2) || (s_f_s_op1 + (float)m_l_op2 != s_f_s_op1 + i_l_op2) || (s_f_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 19 failed"); passed = false; } if ((s_f_s_op1 + s_i_s_op2 != s_f_s_op1 + s_ui_s_op2) || (s_f_s_op1 + s_ui_s_op2 != s_f_s_op1 + s_l_s_op2) || (s_f_s_op1 + s_l_s_op2 != s_f_s_op1 + s_ul_s_op2) || (s_f_s_op1 + s_ul_s_op2 != s_f_s_op1 + s_f_s_op2) || (s_f_s_op1 + s_f_s_op2 != s_f_s_op1 + s_d_s_op2) || (s_f_s_op1 + s_d_s_op2 != s_f_s_op1 + (float)s_m_s_op2) || (s_f_s_op1 + (float)s_m_s_op2 != s_f_s_op1 + s_i_s_op2) || (s_f_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 20 failed"); passed = false; } } { double d_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((d_l_op1 + i_l_op2 != d_l_op1 + ui_l_op2) || (d_l_op1 + ui_l_op2 != d_l_op1 + l_l_op2) || (d_l_op1 + l_l_op2 != d_l_op1 + ul_l_op2) || (d_l_op1 + ul_l_op2 != d_l_op1 + f_l_op2) || (d_l_op1 + f_l_op2 != d_l_op1 + d_l_op2) || (d_l_op1 + d_l_op2 != d_l_op1 + (double)m_l_op2) || (d_l_op1 + (double)m_l_op2 != d_l_op1 + i_l_op2) || (d_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 21 failed"); passed = false; } if ((d_l_op1 + s_i_s_op2 != d_l_op1 + s_ui_s_op2) || (d_l_op1 + s_ui_s_op2 != d_l_op1 + s_l_s_op2) || (d_l_op1 + s_l_s_op2 != d_l_op1 + s_ul_s_op2) || (d_l_op1 + s_ul_s_op2 != d_l_op1 + s_f_s_op2) || (d_l_op1 + s_f_s_op2 != d_l_op1 + s_d_s_op2) || (d_l_op1 + s_d_s_op2 != d_l_op1 + (double)s_m_s_op2) || (d_l_op1 + (double)s_m_s_op2 != d_l_op1 + s_i_s_op2) || (d_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 22 failed"); passed = false; } if ((s_d_s_op1 + i_l_op2 != s_d_s_op1 + ui_l_op2) || (s_d_s_op1 + ui_l_op2 != s_d_s_op1 + l_l_op2) || (s_d_s_op1 + l_l_op2 != s_d_s_op1 + ul_l_op2) || (s_d_s_op1 + ul_l_op2 != s_d_s_op1 + f_l_op2) || (s_d_s_op1 + f_l_op2 != s_d_s_op1 + d_l_op2) || (s_d_s_op1 + d_l_op2 != s_d_s_op1 + (double)m_l_op2) || (s_d_s_op1 + (double)m_l_op2 != s_d_s_op1 + i_l_op2) || (s_d_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 23 failed"); passed = false; } if ((s_d_s_op1 + s_i_s_op2 != s_d_s_op1 + s_ui_s_op2) || (s_d_s_op1 + s_ui_s_op2 != s_d_s_op1 + s_l_s_op2) || (s_d_s_op1 + s_l_s_op2 != s_d_s_op1 + s_ul_s_op2) || (s_d_s_op1 + s_ul_s_op2 != s_d_s_op1 + s_f_s_op2) || (s_d_s_op1 + s_f_s_op2 != s_d_s_op1 + s_d_s_op2) || (s_d_s_op1 + s_d_s_op2 != s_d_s_op1 + (double)s_m_s_op2) || (s_d_s_op1 + (double)s_m_s_op2 != s_d_s_op1 + s_i_s_op2) || (s_d_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 24 failed"); passed = false; } } { decimal m_l_op1 = 1; int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((m_l_op1 + i_l_op2 != m_l_op1 + ui_l_op2) || (m_l_op1 + ui_l_op2 != m_l_op1 + l_l_op2) || (m_l_op1 + l_l_op2 != m_l_op1 + ul_l_op2) || (m_l_op1 + ul_l_op2 != m_l_op1 + (decimal)f_l_op2) || (m_l_op1 + (decimal)f_l_op2 != m_l_op1 + (decimal)d_l_op2) || (m_l_op1 + (decimal)d_l_op2 != m_l_op1 + m_l_op2) || (m_l_op1 + m_l_op2 != m_l_op1 + i_l_op2) || (m_l_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 25 failed"); passed = false; } if ((m_l_op1 + s_i_s_op2 != m_l_op1 + s_ui_s_op2) || (m_l_op1 + s_ui_s_op2 != m_l_op1 + s_l_s_op2) || (m_l_op1 + s_l_s_op2 != m_l_op1 + s_ul_s_op2) || (m_l_op1 + s_ul_s_op2 != m_l_op1 + (decimal)s_f_s_op2) || (m_l_op1 + (decimal)s_f_s_op2 != m_l_op1 + (decimal)s_d_s_op2) || (m_l_op1 + (decimal)s_d_s_op2 != m_l_op1 + s_m_s_op2) || (m_l_op1 + s_m_s_op2 != m_l_op1 + s_i_s_op2) || (m_l_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 26 failed"); passed = false; } if ((s_m_s_op1 + i_l_op2 != s_m_s_op1 + ui_l_op2) || (s_m_s_op1 + ui_l_op2 != s_m_s_op1 + l_l_op2) || (s_m_s_op1 + l_l_op2 != s_m_s_op1 + ul_l_op2) || (s_m_s_op1 + ul_l_op2 != s_m_s_op1 + (decimal)f_l_op2) || (s_m_s_op1 + (decimal)f_l_op2 != s_m_s_op1 + (decimal)d_l_op2) || (s_m_s_op1 + (decimal)d_l_op2 != s_m_s_op1 + m_l_op2) || (s_m_s_op1 + m_l_op2 != s_m_s_op1 + i_l_op2) || (s_m_s_op1 + i_l_op2 != 9)) { Console.WriteLine("testcase 27 failed"); passed = false; } if ((s_m_s_op1 + s_i_s_op2 != s_m_s_op1 + s_ui_s_op2) || (s_m_s_op1 + s_ui_s_op2 != s_m_s_op1 + s_l_s_op2) || (s_m_s_op1 + s_l_s_op2 != s_m_s_op1 + s_ul_s_op2) || (s_m_s_op1 + s_ul_s_op2 != s_m_s_op1 + (decimal)s_f_s_op2) || (s_m_s_op1 + (decimal)s_f_s_op2 != s_m_s_op1 + (decimal)s_d_s_op2) || (s_m_s_op1 + (decimal)s_d_s_op2 != s_m_s_op1 + s_m_s_op2) || (s_m_s_op1 + s_m_s_op2 != s_m_s_op1 + s_i_s_op2) || (s_m_s_op1 + s_i_s_op2 != 9)) { Console.WriteLine("testcase 28 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool pass = true; VT vt1; vt1.decimal2darr = new decimal[,] { { 0, -1 }, { 0, 0 } }; vt1.decimal3darr = new decimal[,,] { { { 0, 0 } }, { { 0, -1 } }, { { 0, 0 } } }; vt1.decimal2darr_b = new decimal[,] { { 0, 1 }, { 0, 0 } }; vt1.decimal3darr_b = new decimal[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; CL cl1 = new CL(); ja1[0] = new decimal[,] { { 0, -1 }, { 0, 0 } }; ja2[1] = new decimal[,,] { { { 0, 0 } }, { { 0, -1 } }, { { 0, 0 } } }; ja1_b[0] = new decimal[,] { { 0, 1 }, { 0, 0 } }; ja2_b[1] = new decimal[,,] { { { 0, 0 } }, { { 0, 1 } }, { { 0, 0 } } }; decimal result = -1; // 2D if (result != decimal2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.decimal2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.decimal2darr[0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja1[0][0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (result != decimal3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != vt1.decimal3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != cl1.decimal3darr[1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (result != ja2[1][1, 0, 1]) { Console.WriteLine("ERROR:"); Console.WriteLine("result is: {0}", result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToByte tests byte Byte_result = 1; // 2D if (Byte_result != Convert.ToByte(decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.decimal2darr_b[0, 1] is: {0}", vt1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.decimal2darr_b[0, 1] is: {0}", cl1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Byte_result != Convert.ToByte(decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("decimal3darr_b[1,0,1] is: {0}", decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(vt1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("vt1.decimal3darr_b[1,0,1] is: {0}", vt1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(cl1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("cl1.decimal3darr_b[1,0,1] is: {0}", cl1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Byte_result != Convert.ToByte(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Byte_result is: {0}", Byte_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToDouble double double_result = -1; // 2D if (double_result != Convert.ToDouble(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (double_result != Convert.ToDouble(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (double_result != Convert.ToDouble(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("double_result is: {0}", double_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DeimalToSingle Single Single_result = -1; // 2D if (Single_result != Convert.ToSingle(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Single_result != Convert.ToSingle(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Single_result != Convert.ToSingle(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Single_result is: {0}", Single_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToInt32 tests int Int32_result = -1; // 2D if (Int32_result != Convert.ToInt32(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int32_result != Convert.ToInt32(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int32_result != Convert.ToInt32(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int32_result is: {0}", Int32_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToInt64 tests long Int64_result = -1; // 2D if (Int64_result != Convert.ToInt64(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int64_result != Convert.ToInt64(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int64_result != Convert.ToInt64(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int64_result is: {0}", Int64_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToSByte tests sbyte SByte_result = -1; // 2D if (SByte_result != Convert.ToSByte(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (SByte_result != Convert.ToSByte(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (SByte_result != Convert.ToSByte(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("SByte_result is: {0}", SByte_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToInt16 tests short Int16_result = -1; // 2D if (Int16_result != Convert.ToInt16(decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.decimal2darr[0, 1] is: {0}", vt1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.decimal2darr[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.decimal2darr[0, 1] is: {0}", cl1.decimal2darr[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja1[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja1[0][0, 1] is: {0}", ja1[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (Int16_result != Convert.ToInt16(decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("decimal3darr[1,0,1] is: {0}", decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(vt1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("vt1.decimal3darr[1,0,1] is: {0}", vt1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(cl1.decimal3darr[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("cl1.decimal3darr[1,0,1] is: {0}", cl1.decimal3darr[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (Int16_result != Convert.ToInt16(ja2[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("Int16_result is: {0}", Int16_result); Console.WriteLine("ja2[1][1,0,1] is: {0}", ja2[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToUInt32 tests uint UInt32_result = 1; // 2D if (UInt32_result != Convert.ToUInt32(decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.decimal2darr_b[0, 1] is: {0}", vt1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.decimal2darr_b[0, 1] is: {0}", cl1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt32_result != Convert.ToUInt32(decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("decimal3darr_b[1,0,1] is: {0}", decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(vt1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("vt1.decimal3darr_b[1,0,1] is: {0}", vt1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(cl1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("cl1.decimal3darr_b[1,0,1] is: {0}", cl1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt32_result != Convert.ToUInt32(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt32_result is: {0}", UInt32_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToUInt64 tests ulong UInt64_result = 1; // 2D if (UInt64_result != Convert.ToUInt64(decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.decimal2darr_b[0, 1] is: {0}", vt1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.decimal2darr_b[0, 1] is: {0}", cl1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt64_result != Convert.ToUInt64(decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("decimal3darr_b[1,0,1] is: {0}", decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(vt1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("vt1.decimal3darr_b[1,0,1] is: {0}", vt1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(cl1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("cl1.decimal3darr_b[1,0,1] is: {0}", cl1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt64_result != Convert.ToUInt64(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt64_result is: {0}", UInt64_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } //DecimalToUInt16 tests ushort UInt16_result = 1; // 2D if (UInt16_result != Convert.ToUInt16(decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("2darr[0, 1] is: {0}", decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.decimal2darr_b[0, 1] is: {0}", vt1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.decimal2darr_b[0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.decimal2darr_b[0, 1] is: {0}", cl1.decimal2darr_b[0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja1_b[0][0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja1_b[0][0, 1] is: {0}", ja1_b[0][0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } // 3D if (UInt16_result != Convert.ToUInt16(decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("decimal3darr_b[1,0,1] is: {0}", decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(vt1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("vt1.decimal3darr_b[1,0,1] is: {0}", vt1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(cl1.decimal3darr_b[1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("cl1.decimal3darr_b[1,0,1] is: {0}", cl1.decimal3darr_b[1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (UInt16_result != Convert.ToUInt16(ja2_b[1][1, 0, 1])) { Console.WriteLine("ERROR:"); Console.WriteLine("UInt16_result is: {0}", UInt16_result); Console.WriteLine("ja2_b[1][1,0,1] is: {0}", ja2_b[1][1, 0, 1]); Console.WriteLine("and they are NOT equal !"); Console.WriteLine(); pass = false; } if (!pass) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.nHldr_vt_op1 = new numHolder(65); vt1.i_vt_op2 = 8; vt1.ui_vt_op2 = 8; vt1.l_vt_op2 = 8; vt1.ul_vt_op2 = 8; vt1.f_vt_op2 = 8; vt1.d_vt_op2 = 8; vt1.m_vt_op2 = 8; vt1.nHldr_vt_op2 = new numHolder(8); numHolder[] nHldr_arr1d_op1 = { new numHolder(0), new numHolder(65) }; numHolder[,] nHldr_arr2d_op1 = { { new numHolder(0), new numHolder(65) }, { new numHolder(1), new numHolder(1) } }; numHolder[,,] nHldr_arr3d_op1 = { { { new numHolder(0), new numHolder(65) }, { new numHolder(1), new numHolder(1) } } }; int[] i_arr1d_op2 = { 8, 0, 1 }; int[,] i_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; int[,,] i_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; uint[] ui_arr1d_op2 = { 8, 0, 1 }; uint[,] ui_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; uint[,,] ui_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; long[] l_arr1d_op2 = { 8, 0, 1 }; long[,] l_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; long[,,] l_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; ulong[] ul_arr1d_op2 = { 8, 0, 1 }; ulong[,] ul_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; ulong[,,] ul_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; float[] f_arr1d_op2 = { 8, 0, 1 }; float[,] f_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; float[,,] f_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; double[] d_arr1d_op2 = { 8, 0, 1 }; double[,] d_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; double[,,] d_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; decimal[] m_arr1d_op2 = { 8, 0, 1 }; decimal[,] m_arr2d_op2 = { { 0, 8 }, { 1, 1 } }; decimal[,,] m_arr3d_op2 = { { { 0, 8 }, { 1, 1 } } }; numHolder[] nHldr_arr1d_op2 = { new numHolder(8), new numHolder(0), new numHolder(1) }; numHolder[,] nHldr_arr2d_op2 = { { new numHolder(0), new numHolder(8) }, { new numHolder(1), new numHolder(1) } }; numHolder[,,] nHldr_arr3d_op2 = { { { new numHolder(0), new numHolder(8) }, { new numHolder(1), new numHolder(1) } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { numHolder nHldr_l_op1 = new numHolder(65); int i_l_op2 = 8; uint ui_l_op2 = 8; long l_l_op2 = 8; ulong ul_l_op2 = 8; float f_l_op2 = 8; double d_l_op2 = 8; decimal m_l_op2 = 8; numHolder nHldr_l_op2 = new numHolder(8); if ((nHldr_l_op1 % i_l_op2 != nHldr_l_op1 % ui_l_op2) || (nHldr_l_op1 % ui_l_op2 != nHldr_l_op1 % l_l_op2) || (nHldr_l_op1 % l_l_op2 != nHldr_l_op1 % ul_l_op2) || (nHldr_l_op1 % ul_l_op2 != nHldr_l_op1 % f_l_op2) || (nHldr_l_op1 % f_l_op2 != nHldr_l_op1 % d_l_op2) || (nHldr_l_op1 % d_l_op2 != nHldr_l_op1 % m_l_op2) || (nHldr_l_op1 % m_l_op2 != nHldr_l_op1 % i_l_op2) || (nHldr_l_op1 % i_l_op2 != 1)) { Console.WriteLine("testcase 1 failed"); passed = false; } if ((nHldr_l_op1 % s_i_s_op2 != nHldr_l_op1 % s_ui_s_op2) || (nHldr_l_op1 % s_ui_s_op2 != nHldr_l_op1 % s_l_s_op2) || (nHldr_l_op1 % s_l_s_op2 != nHldr_l_op1 % s_ul_s_op2) || (nHldr_l_op1 % s_ul_s_op2 != nHldr_l_op1 % s_f_s_op2) || (nHldr_l_op1 % s_f_s_op2 != nHldr_l_op1 % s_d_s_op2) || (nHldr_l_op1 % s_d_s_op2 != nHldr_l_op1 % s_m_s_op2) || (nHldr_l_op1 % s_m_s_op2 != nHldr_l_op1 % s_i_s_op2) || (nHldr_l_op1 % s_i_s_op2 != 1)) { Console.WriteLine("testcase 2 failed"); passed = false; } if ((nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != nHldr_l_op1 % nHldr_f("op2")) || (nHldr_l_op1 % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 3 failed"); passed = false; } if ((nHldr_l_op1 % cl1.i_cl_op2 != nHldr_l_op1 % cl1.ui_cl_op2) || (nHldr_l_op1 % cl1.ui_cl_op2 != nHldr_l_op1 % cl1.l_cl_op2) || (nHldr_l_op1 % cl1.l_cl_op2 != nHldr_l_op1 % cl1.ul_cl_op2) || (nHldr_l_op1 % cl1.ul_cl_op2 != nHldr_l_op1 % cl1.f_cl_op2) || (nHldr_l_op1 % cl1.f_cl_op2 != nHldr_l_op1 % cl1.d_cl_op2) || (nHldr_l_op1 % cl1.d_cl_op2 != nHldr_l_op1 % cl1.m_cl_op2) || (nHldr_l_op1 % cl1.m_cl_op2 != nHldr_l_op1 % cl1.i_cl_op2) || (nHldr_l_op1 % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 4 failed"); passed = false; } if ((nHldr_l_op1 % vt1.i_vt_op2 != nHldr_l_op1 % vt1.ui_vt_op2) || (nHldr_l_op1 % vt1.ui_vt_op2 != nHldr_l_op1 % vt1.l_vt_op2) || (nHldr_l_op1 % vt1.l_vt_op2 != nHldr_l_op1 % vt1.ul_vt_op2) || (nHldr_l_op1 % vt1.ul_vt_op2 != nHldr_l_op1 % vt1.f_vt_op2) || (nHldr_l_op1 % vt1.f_vt_op2 != nHldr_l_op1 % vt1.d_vt_op2) || (nHldr_l_op1 % vt1.d_vt_op2 != nHldr_l_op1 % vt1.m_vt_op2) || (nHldr_l_op1 % vt1.m_vt_op2 != nHldr_l_op1 % vt1.i_vt_op2) || (nHldr_l_op1 % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 5 failed"); passed = false; } if ((nHldr_l_op1 % i_arr1d_op2[0] != nHldr_l_op1 % ui_arr1d_op2[0]) || (nHldr_l_op1 % ui_arr1d_op2[0] != nHldr_l_op1 % l_arr1d_op2[0]) || (nHldr_l_op1 % l_arr1d_op2[0] != nHldr_l_op1 % ul_arr1d_op2[0]) || (nHldr_l_op1 % ul_arr1d_op2[0] != nHldr_l_op1 % f_arr1d_op2[0]) || (nHldr_l_op1 % f_arr1d_op2[0] != nHldr_l_op1 % d_arr1d_op2[0]) || (nHldr_l_op1 % d_arr1d_op2[0] != nHldr_l_op1 % m_arr1d_op2[0]) || (nHldr_l_op1 % m_arr1d_op2[0] != nHldr_l_op1 % i_arr1d_op2[0]) || (nHldr_l_op1 % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 6 failed"); passed = false; } if ((nHldr_l_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % l_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % l_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % d_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_l_op1 % i_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_l_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 7 failed"); passed = false; } if ((nHldr_l_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_l_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_l_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 8 failed"); passed = false; } if ((s_nHldr_s_op1 % i_l_op2 != s_nHldr_s_op1 % ui_l_op2) || (s_nHldr_s_op1 % ui_l_op2 != s_nHldr_s_op1 % l_l_op2) || (s_nHldr_s_op1 % l_l_op2 != s_nHldr_s_op1 % ul_l_op2) || (s_nHldr_s_op1 % ul_l_op2 != s_nHldr_s_op1 % f_l_op2) || (s_nHldr_s_op1 % f_l_op2 != s_nHldr_s_op1 % d_l_op2) || (s_nHldr_s_op1 % d_l_op2 != s_nHldr_s_op1 % m_l_op2) || (s_nHldr_s_op1 % m_l_op2 != s_nHldr_s_op1 % i_l_op2) || (s_nHldr_s_op1 % i_l_op2 != 1)) { Console.WriteLine("testcase 9 failed"); passed = false; } if ((s_nHldr_s_op1 % s_i_s_op2 != s_nHldr_s_op1 % s_ui_s_op2) || (s_nHldr_s_op1 % s_ui_s_op2 != s_nHldr_s_op1 % s_l_s_op2) || (s_nHldr_s_op1 % s_l_s_op2 != s_nHldr_s_op1 % s_ul_s_op2) || (s_nHldr_s_op1 % s_ul_s_op2 != s_nHldr_s_op1 % s_f_s_op2) || (s_nHldr_s_op1 % s_f_s_op2 != s_nHldr_s_op1 % s_d_s_op2) || (s_nHldr_s_op1 % s_d_s_op2 != s_nHldr_s_op1 % s_m_s_op2) || (s_nHldr_s_op1 % s_m_s_op2 != s_nHldr_s_op1 % s_i_s_op2) || (s_nHldr_s_op1 % s_i_s_op2 != 1)) { Console.WriteLine("testcase 10 failed"); passed = false; } if ((s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != s_nHldr_s_op1 % nHldr_f("op2")) || (s_nHldr_s_op1 % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 11 failed"); passed = false; } if ((s_nHldr_s_op1 % cl1.i_cl_op2 != s_nHldr_s_op1 % cl1.ui_cl_op2) || (s_nHldr_s_op1 % cl1.ui_cl_op2 != s_nHldr_s_op1 % cl1.l_cl_op2) || (s_nHldr_s_op1 % cl1.l_cl_op2 != s_nHldr_s_op1 % cl1.ul_cl_op2) || (s_nHldr_s_op1 % cl1.ul_cl_op2 != s_nHldr_s_op1 % cl1.f_cl_op2) || (s_nHldr_s_op1 % cl1.f_cl_op2 != s_nHldr_s_op1 % cl1.d_cl_op2) || (s_nHldr_s_op1 % cl1.d_cl_op2 != s_nHldr_s_op1 % cl1.m_cl_op2) || (s_nHldr_s_op1 % cl1.m_cl_op2 != s_nHldr_s_op1 % cl1.i_cl_op2) || (s_nHldr_s_op1 % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 12 failed"); passed = false; } if ((s_nHldr_s_op1 % vt1.i_vt_op2 != s_nHldr_s_op1 % vt1.ui_vt_op2) || (s_nHldr_s_op1 % vt1.ui_vt_op2 != s_nHldr_s_op1 % vt1.l_vt_op2) || (s_nHldr_s_op1 % vt1.l_vt_op2 != s_nHldr_s_op1 % vt1.ul_vt_op2) || (s_nHldr_s_op1 % vt1.ul_vt_op2 != s_nHldr_s_op1 % vt1.f_vt_op2) || (s_nHldr_s_op1 % vt1.f_vt_op2 != s_nHldr_s_op1 % vt1.d_vt_op2) || (s_nHldr_s_op1 % vt1.d_vt_op2 != s_nHldr_s_op1 % vt1.m_vt_op2) || (s_nHldr_s_op1 % vt1.m_vt_op2 != s_nHldr_s_op1 % vt1.i_vt_op2) || (s_nHldr_s_op1 % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 13 failed"); passed = false; } if ((s_nHldr_s_op1 % i_arr1d_op2[0] != s_nHldr_s_op1 % ui_arr1d_op2[0]) || (s_nHldr_s_op1 % ui_arr1d_op2[0] != s_nHldr_s_op1 % l_arr1d_op2[0]) || (s_nHldr_s_op1 % l_arr1d_op2[0] != s_nHldr_s_op1 % ul_arr1d_op2[0]) || (s_nHldr_s_op1 % ul_arr1d_op2[0] != s_nHldr_s_op1 % f_arr1d_op2[0]) || (s_nHldr_s_op1 % f_arr1d_op2[0] != s_nHldr_s_op1 % d_arr1d_op2[0]) || (s_nHldr_s_op1 % d_arr1d_op2[0] != s_nHldr_s_op1 % m_arr1d_op2[0]) || (s_nHldr_s_op1 % m_arr1d_op2[0] != s_nHldr_s_op1 % i_arr1d_op2[0]) || (s_nHldr_s_op1 % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 14 failed"); passed = false; } if ((s_nHldr_s_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % l_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % l_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % d_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != s_nHldr_s_op1 % i_arr2d_op2[index[0, 1], index[1, 0]]) || (s_nHldr_s_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 15 failed"); passed = false; } if ((s_nHldr_s_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_nHldr_s_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_nHldr_s_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 16 failed"); passed = false; } if ((nHldr_f("op1") % i_l_op2 != nHldr_f("op1") % ui_l_op2) || (nHldr_f("op1") % ui_l_op2 != nHldr_f("op1") % l_l_op2) || (nHldr_f("op1") % l_l_op2 != nHldr_f("op1") % ul_l_op2) || (nHldr_f("op1") % ul_l_op2 != nHldr_f("op1") % f_l_op2) || (nHldr_f("op1") % f_l_op2 != nHldr_f("op1") % d_l_op2) || (nHldr_f("op1") % d_l_op2 != nHldr_f("op1") % m_l_op2) || (nHldr_f("op1") % m_l_op2 != nHldr_f("op1") % i_l_op2) || (nHldr_f("op1") % i_l_op2 != 1)) { Console.WriteLine("testcase 17 failed"); passed = false; } if ((nHldr_f("op1") % s_i_s_op2 != nHldr_f("op1") % s_ui_s_op2) || (nHldr_f("op1") % s_ui_s_op2 != nHldr_f("op1") % s_l_s_op2) || (nHldr_f("op1") % s_l_s_op2 != nHldr_f("op1") % s_ul_s_op2) || (nHldr_f("op1") % s_ul_s_op2 != nHldr_f("op1") % s_f_s_op2) || (nHldr_f("op1") % s_f_s_op2 != nHldr_f("op1") % s_d_s_op2) || (nHldr_f("op1") % s_d_s_op2 != nHldr_f("op1") % s_m_s_op2) || (nHldr_f("op1") % s_m_s_op2 != nHldr_f("op1") % s_i_s_op2) || (nHldr_f("op1") % s_i_s_op2 != 1)) { Console.WriteLine("testcase 18 failed"); passed = false; } if ((nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != nHldr_f("op1") % nHldr_f("op2")) || (nHldr_f("op1") % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 19 failed"); passed = false; } if ((nHldr_f("op1") % cl1.i_cl_op2 != nHldr_f("op1") % cl1.ui_cl_op2) || (nHldr_f("op1") % cl1.ui_cl_op2 != nHldr_f("op1") % cl1.l_cl_op2) || (nHldr_f("op1") % cl1.l_cl_op2 != nHldr_f("op1") % cl1.ul_cl_op2) || (nHldr_f("op1") % cl1.ul_cl_op2 != nHldr_f("op1") % cl1.f_cl_op2) || (nHldr_f("op1") % cl1.f_cl_op2 != nHldr_f("op1") % cl1.d_cl_op2) || (nHldr_f("op1") % cl1.d_cl_op2 != nHldr_f("op1") % cl1.m_cl_op2) || (nHldr_f("op1") % cl1.m_cl_op2 != nHldr_f("op1") % cl1.i_cl_op2) || (nHldr_f("op1") % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 20 failed"); passed = false; } if ((nHldr_f("op1") % vt1.i_vt_op2 != nHldr_f("op1") % vt1.ui_vt_op2) || (nHldr_f("op1") % vt1.ui_vt_op2 != nHldr_f("op1") % vt1.l_vt_op2) || (nHldr_f("op1") % vt1.l_vt_op2 != nHldr_f("op1") % vt1.ul_vt_op2) || (nHldr_f("op1") % vt1.ul_vt_op2 != nHldr_f("op1") % vt1.f_vt_op2) || (nHldr_f("op1") % vt1.f_vt_op2 != nHldr_f("op1") % vt1.d_vt_op2) || (nHldr_f("op1") % vt1.d_vt_op2 != nHldr_f("op1") % vt1.m_vt_op2) || (nHldr_f("op1") % vt1.m_vt_op2 != nHldr_f("op1") % vt1.i_vt_op2) || (nHldr_f("op1") % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 21 failed"); passed = false; } if ((nHldr_f("op1") % i_arr1d_op2[0] != nHldr_f("op1") % ui_arr1d_op2[0]) || (nHldr_f("op1") % ui_arr1d_op2[0] != nHldr_f("op1") % l_arr1d_op2[0]) || (nHldr_f("op1") % l_arr1d_op2[0] != nHldr_f("op1") % ul_arr1d_op2[0]) || (nHldr_f("op1") % ul_arr1d_op2[0] != nHldr_f("op1") % f_arr1d_op2[0]) || (nHldr_f("op1") % f_arr1d_op2[0] != nHldr_f("op1") % d_arr1d_op2[0]) || (nHldr_f("op1") % d_arr1d_op2[0] != nHldr_f("op1") % m_arr1d_op2[0]) || (nHldr_f("op1") % m_arr1d_op2[0] != nHldr_f("op1") % i_arr1d_op2[0]) || (nHldr_f("op1") % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 22 failed"); passed = false; } if ((nHldr_f("op1") % i_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % ui_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % l_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % l_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % ul_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % f_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % f_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % d_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % d_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % m_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % m_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_f("op1") % i_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_f("op1") % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 23 failed"); passed = false; } if ((nHldr_f("op1") % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_f("op1") % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_f("op1") % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 24 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % i_l_op2 != cl1.nHldr_cl_op1 % ui_l_op2) || (cl1.nHldr_cl_op1 % ui_l_op2 != cl1.nHldr_cl_op1 % l_l_op2) || (cl1.nHldr_cl_op1 % l_l_op2 != cl1.nHldr_cl_op1 % ul_l_op2) || (cl1.nHldr_cl_op1 % ul_l_op2 != cl1.nHldr_cl_op1 % f_l_op2) || (cl1.nHldr_cl_op1 % f_l_op2 != cl1.nHldr_cl_op1 % d_l_op2) || (cl1.nHldr_cl_op1 % d_l_op2 != cl1.nHldr_cl_op1 % m_l_op2) || (cl1.nHldr_cl_op1 % m_l_op2 != cl1.nHldr_cl_op1 % i_l_op2) || (cl1.nHldr_cl_op1 % i_l_op2 != 1)) { Console.WriteLine("testcase 25 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % s_i_s_op2 != cl1.nHldr_cl_op1 % s_ui_s_op2) || (cl1.nHldr_cl_op1 % s_ui_s_op2 != cl1.nHldr_cl_op1 % s_l_s_op2) || (cl1.nHldr_cl_op1 % s_l_s_op2 != cl1.nHldr_cl_op1 % s_ul_s_op2) || (cl1.nHldr_cl_op1 % s_ul_s_op2 != cl1.nHldr_cl_op1 % s_f_s_op2) || (cl1.nHldr_cl_op1 % s_f_s_op2 != cl1.nHldr_cl_op1 % s_d_s_op2) || (cl1.nHldr_cl_op1 % s_d_s_op2 != cl1.nHldr_cl_op1 % s_m_s_op2) || (cl1.nHldr_cl_op1 % s_m_s_op2 != cl1.nHldr_cl_op1 % s_i_s_op2) || (cl1.nHldr_cl_op1 % s_i_s_op2 != 1)) { Console.WriteLine("testcase 26 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != cl1.nHldr_cl_op1 % nHldr_f("op2")) || (cl1.nHldr_cl_op1 % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 27 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % cl1.i_cl_op2 != cl1.nHldr_cl_op1 % cl1.ui_cl_op2) || (cl1.nHldr_cl_op1 % cl1.ui_cl_op2 != cl1.nHldr_cl_op1 % cl1.l_cl_op2) || (cl1.nHldr_cl_op1 % cl1.l_cl_op2 != cl1.nHldr_cl_op1 % cl1.ul_cl_op2) || (cl1.nHldr_cl_op1 % cl1.ul_cl_op2 != cl1.nHldr_cl_op1 % cl1.f_cl_op2) || (cl1.nHldr_cl_op1 % cl1.f_cl_op2 != cl1.nHldr_cl_op1 % cl1.d_cl_op2) || (cl1.nHldr_cl_op1 % cl1.d_cl_op2 != cl1.nHldr_cl_op1 % cl1.m_cl_op2) || (cl1.nHldr_cl_op1 % cl1.m_cl_op2 != cl1.nHldr_cl_op1 % cl1.i_cl_op2) || (cl1.nHldr_cl_op1 % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 28 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % vt1.i_vt_op2 != cl1.nHldr_cl_op1 % vt1.ui_vt_op2) || (cl1.nHldr_cl_op1 % vt1.ui_vt_op2 != cl1.nHldr_cl_op1 % vt1.l_vt_op2) || (cl1.nHldr_cl_op1 % vt1.l_vt_op2 != cl1.nHldr_cl_op1 % vt1.ul_vt_op2) || (cl1.nHldr_cl_op1 % vt1.ul_vt_op2 != cl1.nHldr_cl_op1 % vt1.f_vt_op2) || (cl1.nHldr_cl_op1 % vt1.f_vt_op2 != cl1.nHldr_cl_op1 % vt1.d_vt_op2) || (cl1.nHldr_cl_op1 % vt1.d_vt_op2 != cl1.nHldr_cl_op1 % vt1.m_vt_op2) || (cl1.nHldr_cl_op1 % vt1.m_vt_op2 != cl1.nHldr_cl_op1 % vt1.i_vt_op2) || (cl1.nHldr_cl_op1 % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 29 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % i_arr1d_op2[0] != cl1.nHldr_cl_op1 % ui_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % ui_arr1d_op2[0] != cl1.nHldr_cl_op1 % l_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % l_arr1d_op2[0] != cl1.nHldr_cl_op1 % ul_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % ul_arr1d_op2[0] != cl1.nHldr_cl_op1 % f_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % f_arr1d_op2[0] != cl1.nHldr_cl_op1 % d_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % d_arr1d_op2[0] != cl1.nHldr_cl_op1 % m_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % m_arr1d_op2[0] != cl1.nHldr_cl_op1 % i_arr1d_op2[0]) || (cl1.nHldr_cl_op1 % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 30 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % l_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % l_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % d_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != cl1.nHldr_cl_op1 % i_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.nHldr_cl_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 31 failed"); passed = false; } if ((cl1.nHldr_cl_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.nHldr_cl_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.nHldr_cl_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 32 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % i_l_op2 != vt1.nHldr_vt_op1 % ui_l_op2) || (vt1.nHldr_vt_op1 % ui_l_op2 != vt1.nHldr_vt_op1 % l_l_op2) || (vt1.nHldr_vt_op1 % l_l_op2 != vt1.nHldr_vt_op1 % ul_l_op2) || (vt1.nHldr_vt_op1 % ul_l_op2 != vt1.nHldr_vt_op1 % f_l_op2) || (vt1.nHldr_vt_op1 % f_l_op2 != vt1.nHldr_vt_op1 % d_l_op2) || (vt1.nHldr_vt_op1 % d_l_op2 != vt1.nHldr_vt_op1 % m_l_op2) || (vt1.nHldr_vt_op1 % m_l_op2 != vt1.nHldr_vt_op1 % i_l_op2) || (vt1.nHldr_vt_op1 % i_l_op2 != 1)) { Console.WriteLine("testcase 33 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % s_i_s_op2 != vt1.nHldr_vt_op1 % s_ui_s_op2) || (vt1.nHldr_vt_op1 % s_ui_s_op2 != vt1.nHldr_vt_op1 % s_l_s_op2) || (vt1.nHldr_vt_op1 % s_l_s_op2 != vt1.nHldr_vt_op1 % s_ul_s_op2) || (vt1.nHldr_vt_op1 % s_ul_s_op2 != vt1.nHldr_vt_op1 % s_f_s_op2) || (vt1.nHldr_vt_op1 % s_f_s_op2 != vt1.nHldr_vt_op1 % s_d_s_op2) || (vt1.nHldr_vt_op1 % s_d_s_op2 != vt1.nHldr_vt_op1 % s_m_s_op2) || (vt1.nHldr_vt_op1 % s_m_s_op2 != vt1.nHldr_vt_op1 % s_i_s_op2) || (vt1.nHldr_vt_op1 % s_i_s_op2 != 1)) { Console.WriteLine("testcase 34 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != vt1.nHldr_vt_op1 % nHldr_f("op2")) || (vt1.nHldr_vt_op1 % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 35 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % cl1.i_cl_op2 != vt1.nHldr_vt_op1 % cl1.ui_cl_op2) || (vt1.nHldr_vt_op1 % cl1.ui_cl_op2 != vt1.nHldr_vt_op1 % cl1.l_cl_op2) || (vt1.nHldr_vt_op1 % cl1.l_cl_op2 != vt1.nHldr_vt_op1 % cl1.ul_cl_op2) || (vt1.nHldr_vt_op1 % cl1.ul_cl_op2 != vt1.nHldr_vt_op1 % cl1.f_cl_op2) || (vt1.nHldr_vt_op1 % cl1.f_cl_op2 != vt1.nHldr_vt_op1 % cl1.d_cl_op2) || (vt1.nHldr_vt_op1 % cl1.d_cl_op2 != vt1.nHldr_vt_op1 % cl1.m_cl_op2) || (vt1.nHldr_vt_op1 % cl1.m_cl_op2 != vt1.nHldr_vt_op1 % cl1.i_cl_op2) || (vt1.nHldr_vt_op1 % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 36 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % vt1.i_vt_op2 != vt1.nHldr_vt_op1 % vt1.ui_vt_op2) || (vt1.nHldr_vt_op1 % vt1.ui_vt_op2 != vt1.nHldr_vt_op1 % vt1.l_vt_op2) || (vt1.nHldr_vt_op1 % vt1.l_vt_op2 != vt1.nHldr_vt_op1 % vt1.ul_vt_op2) || (vt1.nHldr_vt_op1 % vt1.ul_vt_op2 != vt1.nHldr_vt_op1 % vt1.f_vt_op2) || (vt1.nHldr_vt_op1 % vt1.f_vt_op2 != vt1.nHldr_vt_op1 % vt1.d_vt_op2) || (vt1.nHldr_vt_op1 % vt1.d_vt_op2 != vt1.nHldr_vt_op1 % vt1.m_vt_op2) || (vt1.nHldr_vt_op1 % vt1.m_vt_op2 != vt1.nHldr_vt_op1 % vt1.i_vt_op2) || (vt1.nHldr_vt_op1 % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 37 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % i_arr1d_op2[0] != vt1.nHldr_vt_op1 % ui_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % ui_arr1d_op2[0] != vt1.nHldr_vt_op1 % l_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % l_arr1d_op2[0] != vt1.nHldr_vt_op1 % ul_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % ul_arr1d_op2[0] != vt1.nHldr_vt_op1 % f_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % f_arr1d_op2[0] != vt1.nHldr_vt_op1 % d_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % d_arr1d_op2[0] != vt1.nHldr_vt_op1 % m_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % m_arr1d_op2[0] != vt1.nHldr_vt_op1 % i_arr1d_op2[0]) || (vt1.nHldr_vt_op1 % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 38 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % l_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % l_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % d_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != vt1.nHldr_vt_op1 % i_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.nHldr_vt_op1 % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 39 failed"); passed = false; } if ((vt1.nHldr_vt_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.nHldr_vt_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.nHldr_vt_op1 % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 40 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % i_l_op2 != nHldr_arr1d_op1[1] % ui_l_op2) || (nHldr_arr1d_op1[1] % ui_l_op2 != nHldr_arr1d_op1[1] % l_l_op2) || (nHldr_arr1d_op1[1] % l_l_op2 != nHldr_arr1d_op1[1] % ul_l_op2) || (nHldr_arr1d_op1[1] % ul_l_op2 != nHldr_arr1d_op1[1] % f_l_op2) || (nHldr_arr1d_op1[1] % f_l_op2 != nHldr_arr1d_op1[1] % d_l_op2) || (nHldr_arr1d_op1[1] % d_l_op2 != nHldr_arr1d_op1[1] % m_l_op2) || (nHldr_arr1d_op1[1] % m_l_op2 != nHldr_arr1d_op1[1] % i_l_op2) || (nHldr_arr1d_op1[1] % i_l_op2 != 1)) { Console.WriteLine("testcase 41 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % s_i_s_op2 != nHldr_arr1d_op1[1] % s_ui_s_op2) || (nHldr_arr1d_op1[1] % s_ui_s_op2 != nHldr_arr1d_op1[1] % s_l_s_op2) || (nHldr_arr1d_op1[1] % s_l_s_op2 != nHldr_arr1d_op1[1] % s_ul_s_op2) || (nHldr_arr1d_op1[1] % s_ul_s_op2 != nHldr_arr1d_op1[1] % s_f_s_op2) || (nHldr_arr1d_op1[1] % s_f_s_op2 != nHldr_arr1d_op1[1] % s_d_s_op2) || (nHldr_arr1d_op1[1] % s_d_s_op2 != nHldr_arr1d_op1[1] % s_m_s_op2) || (nHldr_arr1d_op1[1] % s_m_s_op2 != nHldr_arr1d_op1[1] % s_i_s_op2) || (nHldr_arr1d_op1[1] % s_i_s_op2 != 1)) { Console.WriteLine("testcase 42 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != nHldr_arr1d_op1[1] % nHldr_f("op2")) || (nHldr_arr1d_op1[1] % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 43 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % cl1.i_cl_op2 != nHldr_arr1d_op1[1] % cl1.ui_cl_op2) || (nHldr_arr1d_op1[1] % cl1.ui_cl_op2 != nHldr_arr1d_op1[1] % cl1.l_cl_op2) || (nHldr_arr1d_op1[1] % cl1.l_cl_op2 != nHldr_arr1d_op1[1] % cl1.ul_cl_op2) || (nHldr_arr1d_op1[1] % cl1.ul_cl_op2 != nHldr_arr1d_op1[1] % cl1.f_cl_op2) || (nHldr_arr1d_op1[1] % cl1.f_cl_op2 != nHldr_arr1d_op1[1] % cl1.d_cl_op2) || (nHldr_arr1d_op1[1] % cl1.d_cl_op2 != nHldr_arr1d_op1[1] % cl1.m_cl_op2) || (nHldr_arr1d_op1[1] % cl1.m_cl_op2 != nHldr_arr1d_op1[1] % cl1.i_cl_op2) || (nHldr_arr1d_op1[1] % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 44 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % vt1.i_vt_op2 != nHldr_arr1d_op1[1] % vt1.ui_vt_op2) || (nHldr_arr1d_op1[1] % vt1.ui_vt_op2 != nHldr_arr1d_op1[1] % vt1.l_vt_op2) || (nHldr_arr1d_op1[1] % vt1.l_vt_op2 != nHldr_arr1d_op1[1] % vt1.ul_vt_op2) || (nHldr_arr1d_op1[1] % vt1.ul_vt_op2 != nHldr_arr1d_op1[1] % vt1.f_vt_op2) || (nHldr_arr1d_op1[1] % vt1.f_vt_op2 != nHldr_arr1d_op1[1] % vt1.d_vt_op2) || (nHldr_arr1d_op1[1] % vt1.d_vt_op2 != nHldr_arr1d_op1[1] % vt1.m_vt_op2) || (nHldr_arr1d_op1[1] % vt1.m_vt_op2 != nHldr_arr1d_op1[1] % vt1.i_vt_op2) || (nHldr_arr1d_op1[1] % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 45 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % i_arr1d_op2[0] != nHldr_arr1d_op1[1] % ui_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % ui_arr1d_op2[0] != nHldr_arr1d_op1[1] % l_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % l_arr1d_op2[0] != nHldr_arr1d_op1[1] % ul_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % ul_arr1d_op2[0] != nHldr_arr1d_op1[1] % f_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % f_arr1d_op2[0] != nHldr_arr1d_op1[1] % d_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % d_arr1d_op2[0] != nHldr_arr1d_op1[1] % m_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % m_arr1d_op2[0] != nHldr_arr1d_op1[1] % i_arr1d_op2[0]) || (nHldr_arr1d_op1[1] % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 46 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % i_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % ui_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % l_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % l_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % ul_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % f_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % d_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % d_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % m_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr1d_op1[1] % i_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr1d_op1[1] % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 47 failed"); passed = false; } if ((nHldr_arr1d_op1[1] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr1d_op1[1] % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr1d_op1[1] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 48 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_l_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_l_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_l_op2 != 1)) { Console.WriteLine("testcase 49 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_i_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_ui_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_ui_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_l_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_l_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_ul_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_ul_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_f_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_f_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_d_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_d_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_m_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_m_s_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_i_s_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % s_i_s_op2 != 1)) { Console.WriteLine("testcase 50 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2")) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 51 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.i_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ui_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ui_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.l_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.l_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ul_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ul_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.f_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.f_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.d_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.d_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.m_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.m_cl_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.i_cl_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 52 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.i_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ui_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ui_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.l_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.l_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ul_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ul_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.f_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.f_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.d_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.d_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.m_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.m_vt_op2 != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.i_vt_op2) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 53 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr1d_op2[0] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr1d_op2[0]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 54 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 55 failed"); passed = false; } if ((nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr2d_op1[index[0, 1], index[1, 0]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 56 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_l_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_l_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_l_op2 != 1)) { Console.WriteLine("testcase 57 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_i_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ui_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ui_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_l_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_l_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ul_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ul_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_f_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_f_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_d_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_d_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_m_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_m_s_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_i_s_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_i_s_op2 != 1)) { Console.WriteLine("testcase 58 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2")) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % nHldr_f("op2") != 1)) { Console.WriteLine("testcase 59 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.i_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ui_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ui_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.l_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.l_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ul_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ul_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.f_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.f_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.d_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.d_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.m_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.m_cl_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.i_cl_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.i_cl_op2 != 1)) { Console.WriteLine("testcase 60 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.i_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ui_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ui_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.l_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.l_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ul_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ul_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.f_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.f_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.d_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.d_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.m_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.m_vt_op2 != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.i_vt_op2) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.i_vt_op2 != 1)) { Console.WriteLine("testcase 61 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr1d_op2[0] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr1d_op2[0]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr1d_op2[0] != 1)) { Console.WriteLine("testcase 62 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr2d_op2[index[0, 1], index[1, 0]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr2d_op2[index[0, 1], index[1, 0]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr2d_op2[index[0, 1], index[1, 0]] != 1)) { Console.WriteLine("testcase 63 failed"); passed = false; } if ((nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % l_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (nHldr_arr3d_op1[index[0, 0], 0, index[1, 1]] % i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 1)) { Console.WriteLine("testcase 64 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
private string compressCell(CL.Cell DC) { string data = ""; int[] infos = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; infos[0] = (DC.active ? (1) : (0)) << 5; infos[0] = infos[0] | (DC.LoS ? (1) : (0)); infos[0] = infos[0] | (DC.gID & 1536) >> 6; infos[0] = infos[0] | (DC.o1ID & 8192) >> 11; infos[0] = infos[0] | (DC.o2ID & 8192) >> 12; infos[1] = (DC.grot & 3) << 4; infos[1] = infos[1] | DC.glvl & 15; infos[2] = (DC.type & 7) << 3; infos[2] = infos[2] | DC.gID >> 6 & 7; infos[3] = DC.gID & 63; infos[4] = (DC.gslope & 15) << 2; infos[4] = infos[4] | (DC.gflip ? (1) : (0)) << 1; infos[4] = infos[4] | DC.o1ID >> 12 & 1; infos[5] = DC.o1ID >> 6 & 63; infos[6] = DC.o1ID & 63; infos[7] = (DC.o1rot & 3) << 4; infos[7] = infos[7] | (DC.o1flip ? (1) : (0)) << 3; infos[7] = infos[7] | (DC.o2flip ? (1) : (0)) << 2; infos[7] = infos[7] | (DC.o2interactive ? (1) : (0)) << 1; infos[7] = infos[7] | DC.o2ID >> 12 & 1; infos[8] = DC.o2ID >> 6 & 63; infos[9] = DC.o2ID & 63; char[] HASH = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '-', '_'}; foreach (int i in infos) { data += HASH[i]; } return data; }
public static int Main() { bool passed = true; //initialize class CL cl1 = new CL(); //initialize struct VT vt1; vt1.ul_vt_op1 = 27; vt1.i_vt_op2 = 5; vt1.ui_vt_op2 = 5; vt1.l_vt_op2 = 5; vt1.ul_vt_op2 = 5; vt1.f_vt_op2 = 5; vt1.d_vt_op2 = 5; vt1.m_vt_op2 = 5; ulong[] ul_arr1d_op1 = { 0, 27 }; ulong[,] ul_arr2d_op1 = { { 0, 27 }, { 1, 1 } }; ulong[,,] ul_arr3d_op1 = { { { 0, 27 }, { 1, 1 } } }; int[] i_arr1d_op2 = { 5, 0, 1 }; int[,] i_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; int[,,] i_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; uint[] ui_arr1d_op2 = { 5, 0, 1 }; uint[,] ui_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; uint[,,] ui_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; long[] l_arr1d_op2 = { 5, 0, 1 }; long[,] l_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; long[,,] l_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; ulong[] ul_arr1d_op2 = { 5, 0, 1 }; ulong[,] ul_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; ulong[,,] ul_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; float[] f_arr1d_op2 = { 5, 0, 1 }; float[,] f_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; float[,,] f_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; double[] d_arr1d_op2 = { 5, 0, 1 }; double[,] d_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; double[,,] d_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; decimal[] m_arr1d_op2 = { 5, 0, 1 }; decimal[,] m_arr2d_op2 = { { 0, 5 }, { 1, 1 } }; decimal[,,] m_arr3d_op2 = { { { 0, 5 }, { 1, 1 } } }; int[,] index = { { 0, 0 }, { 1, 1 } }; { ulong ul_l_op1 = 27; int i_l_op2 = 5; uint ui_l_op2 = 5; long l_l_op2 = 5; ulong ul_l_op2 = 5; float f_l_op2 = 5; double d_l_op2 = 5; decimal m_l_op2 = 5; if ((ul_l_op1 % (ulong)i_l_op2 != ul_l_op1 % ui_l_op2) || (ul_l_op1 % ui_l_op2 != ul_l_op1 % (ulong)l_l_op2) || (ul_l_op1 % (ulong)l_l_op2 != ul_l_op1 % ul_l_op2) || (ul_l_op1 % ul_l_op2 != ul_l_op1 % f_l_op2) || (ul_l_op1 % f_l_op2 != ul_l_op1 % d_l_op2) || ((decimal)(ul_l_op1 % d_l_op2) != ul_l_op1 % m_l_op2) || (ul_l_op1 % m_l_op2 != ul_l_op1 % (ulong)i_l_op2) || (ul_l_op1 % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 1 failed"); passed = false; } if ((ul_l_op1 % (ulong)s_i_s_op2 != ul_l_op1 % s_ui_s_op2) || (ul_l_op1 % s_ui_s_op2 != ul_l_op1 % (ulong)s_l_s_op2) || (ul_l_op1 % (ulong)s_l_s_op2 != ul_l_op1 % s_ul_s_op2) || (ul_l_op1 % s_ul_s_op2 != ul_l_op1 % s_f_s_op2) || (ul_l_op1 % s_f_s_op2 != ul_l_op1 % s_d_s_op2) || ((decimal)(ul_l_op1 % s_d_s_op2) != ul_l_op1 % s_m_s_op2) || (ul_l_op1 % s_m_s_op2 != ul_l_op1 % (ulong)s_i_s_op2) || (ul_l_op1 % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 2 failed"); passed = false; } if ((ul_l_op1 % (ulong)ul_f("op2") != ul_l_op1 % ul_f("op2")) || (ul_l_op1 % ul_f("op2") != ul_l_op1 % (ulong)ul_f("op2")) || (ul_l_op1 % (ulong)ul_f("op2") != ul_l_op1 % ul_f("op2")) || (ul_l_op1 % ul_f("op2") != ul_l_op1 % ul_f("op2")) || (ul_l_op1 % ul_f("op2") != ul_l_op1 % ul_f("op2")) || ((decimal)(ul_l_op1 % ul_f("op2")) != ul_l_op1 % ul_f("op2")) || (ul_l_op1 % ul_f("op2") != ul_l_op1 % (ulong)ul_f("op2")) || (ul_l_op1 % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 3 failed"); passed = false; } if ((ul_l_op1 % (ulong)cl1.i_cl_op2 != ul_l_op1 % cl1.ui_cl_op2) || (ul_l_op1 % cl1.ui_cl_op2 != ul_l_op1 % (ulong)cl1.l_cl_op2) || (ul_l_op1 % (ulong)cl1.l_cl_op2 != ul_l_op1 % cl1.ul_cl_op2) || (ul_l_op1 % cl1.ul_cl_op2 != ul_l_op1 % cl1.f_cl_op2) || (ul_l_op1 % cl1.f_cl_op2 != ul_l_op1 % cl1.d_cl_op2) || ((decimal)(ul_l_op1 % cl1.d_cl_op2) != ul_l_op1 % cl1.m_cl_op2) || (ul_l_op1 % cl1.m_cl_op2 != ul_l_op1 % (ulong)cl1.i_cl_op2) || (ul_l_op1 % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 4 failed"); passed = false; } if ((ul_l_op1 % (ulong)vt1.i_vt_op2 != ul_l_op1 % vt1.ui_vt_op2) || (ul_l_op1 % vt1.ui_vt_op2 != ul_l_op1 % (ulong)vt1.l_vt_op2) || (ul_l_op1 % (ulong)vt1.l_vt_op2 != ul_l_op1 % vt1.ul_vt_op2) || (ul_l_op1 % vt1.ul_vt_op2 != ul_l_op1 % vt1.f_vt_op2) || (ul_l_op1 % vt1.f_vt_op2 != ul_l_op1 % vt1.d_vt_op2) || ((decimal)(ul_l_op1 % vt1.d_vt_op2) != ul_l_op1 % vt1.m_vt_op2) || (ul_l_op1 % vt1.m_vt_op2 != ul_l_op1 % (ulong)vt1.i_vt_op2) || (ul_l_op1 % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 5 failed"); passed = false; } if ((ul_l_op1 % (ulong)i_arr1d_op2[0] != ul_l_op1 % ui_arr1d_op2[0]) || (ul_l_op1 % ui_arr1d_op2[0] != ul_l_op1 % (ulong)l_arr1d_op2[0]) || (ul_l_op1 % (ulong)l_arr1d_op2[0] != ul_l_op1 % ul_arr1d_op2[0]) || (ul_l_op1 % ul_arr1d_op2[0] != ul_l_op1 % f_arr1d_op2[0]) || (ul_l_op1 % f_arr1d_op2[0] != ul_l_op1 % d_arr1d_op2[0]) || ((decimal)(ul_l_op1 % d_arr1d_op2[0]) != ul_l_op1 % m_arr1d_op2[0]) || (ul_l_op1 % m_arr1d_op2[0] != ul_l_op1 % (ulong)i_arr1d_op2[0]) || (ul_l_op1 % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 6 failed"); passed = false; } if ((ul_l_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(ul_l_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) != ul_l_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != ul_l_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_l_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 7 failed"); passed = false; } if ((ul_l_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(ul_l_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != ul_l_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_l_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_l_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 8 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)i_l_op2 != s_ul_s_op1 % ui_l_op2) || (s_ul_s_op1 % ui_l_op2 != s_ul_s_op1 % (ulong)l_l_op2) || (s_ul_s_op1 % (ulong)l_l_op2 != s_ul_s_op1 % ul_l_op2) || (s_ul_s_op1 % ul_l_op2 != s_ul_s_op1 % f_l_op2) || (s_ul_s_op1 % f_l_op2 != s_ul_s_op1 % d_l_op2) || ((decimal)(s_ul_s_op1 % d_l_op2) != s_ul_s_op1 % m_l_op2) || (s_ul_s_op1 % m_l_op2 != s_ul_s_op1 % (ulong)i_l_op2) || (s_ul_s_op1 % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 9 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)s_i_s_op2 != s_ul_s_op1 % s_ui_s_op2) || (s_ul_s_op1 % s_ui_s_op2 != s_ul_s_op1 % (ulong)s_l_s_op2) || (s_ul_s_op1 % (ulong)s_l_s_op2 != s_ul_s_op1 % s_ul_s_op2) || (s_ul_s_op1 % s_ul_s_op2 != s_ul_s_op1 % s_f_s_op2) || (s_ul_s_op1 % s_f_s_op2 != s_ul_s_op1 % s_d_s_op2) || ((decimal)(s_ul_s_op1 % s_d_s_op2) != s_ul_s_op1 % s_m_s_op2) || (s_ul_s_op1 % s_m_s_op2 != s_ul_s_op1 % (ulong)s_i_s_op2) || (s_ul_s_op1 % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 10 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)ul_f("op2") != s_ul_s_op1 % ul_f("op2")) || (s_ul_s_op1 % ul_f("op2") != s_ul_s_op1 % (ulong)ul_f("op2")) || (s_ul_s_op1 % (ulong)ul_f("op2") != s_ul_s_op1 % ul_f("op2")) || (s_ul_s_op1 % ul_f("op2") != s_ul_s_op1 % ul_f("op2")) || (s_ul_s_op1 % ul_f("op2") != s_ul_s_op1 % ul_f("op2")) || ((decimal)(s_ul_s_op1 % ul_f("op2")) != s_ul_s_op1 % ul_f("op2")) || (s_ul_s_op1 % ul_f("op2") != s_ul_s_op1 % (ulong)ul_f("op2")) || (s_ul_s_op1 % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 11 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)cl1.i_cl_op2 != s_ul_s_op1 % cl1.ui_cl_op2) || (s_ul_s_op1 % cl1.ui_cl_op2 != s_ul_s_op1 % (ulong)cl1.l_cl_op2) || (s_ul_s_op1 % (ulong)cl1.l_cl_op2 != s_ul_s_op1 % cl1.ul_cl_op2) || (s_ul_s_op1 % cl1.ul_cl_op2 != s_ul_s_op1 % cl1.f_cl_op2) || (s_ul_s_op1 % cl1.f_cl_op2 != s_ul_s_op1 % cl1.d_cl_op2) || ((decimal)(s_ul_s_op1 % cl1.d_cl_op2) != s_ul_s_op1 % cl1.m_cl_op2) || (s_ul_s_op1 % cl1.m_cl_op2 != s_ul_s_op1 % (ulong)cl1.i_cl_op2) || (s_ul_s_op1 % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 12 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)vt1.i_vt_op2 != s_ul_s_op1 % vt1.ui_vt_op2) || (s_ul_s_op1 % vt1.ui_vt_op2 != s_ul_s_op1 % (ulong)vt1.l_vt_op2) || (s_ul_s_op1 % (ulong)vt1.l_vt_op2 != s_ul_s_op1 % vt1.ul_vt_op2) || (s_ul_s_op1 % vt1.ul_vt_op2 != s_ul_s_op1 % vt1.f_vt_op2) || (s_ul_s_op1 % vt1.f_vt_op2 != s_ul_s_op1 % vt1.d_vt_op2) || ((decimal)(s_ul_s_op1 % vt1.d_vt_op2) != s_ul_s_op1 % vt1.m_vt_op2) || (s_ul_s_op1 % vt1.m_vt_op2 != s_ul_s_op1 % (ulong)vt1.i_vt_op2) || (s_ul_s_op1 % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 13 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)i_arr1d_op2[0] != s_ul_s_op1 % ui_arr1d_op2[0]) || (s_ul_s_op1 % ui_arr1d_op2[0] != s_ul_s_op1 % (ulong)l_arr1d_op2[0]) || (s_ul_s_op1 % (ulong)l_arr1d_op2[0] != s_ul_s_op1 % ul_arr1d_op2[0]) || (s_ul_s_op1 % ul_arr1d_op2[0] != s_ul_s_op1 % f_arr1d_op2[0]) || (s_ul_s_op1 % f_arr1d_op2[0] != s_ul_s_op1 % d_arr1d_op2[0]) || ((decimal)(s_ul_s_op1 % d_arr1d_op2[0]) != s_ul_s_op1 % m_arr1d_op2[0]) || (s_ul_s_op1 % m_arr1d_op2[0] != s_ul_s_op1 % (ulong)i_arr1d_op2[0]) || (s_ul_s_op1 % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 14 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(s_ul_s_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) != s_ul_s_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != s_ul_s_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (s_ul_s_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 15 failed"); passed = false; } if ((s_ul_s_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(s_ul_s_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != s_ul_s_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != s_ul_s_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (s_ul_s_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 16 failed"); passed = false; } if ((ul_f("op1") % (ulong)i_l_op2 != ul_f("op1") % ui_l_op2) || (ul_f("op1") % ui_l_op2 != ul_f("op1") % (ulong)l_l_op2) || (ul_f("op1") % (ulong)l_l_op2 != ul_f("op1") % ul_l_op2) || (ul_f("op1") % ul_l_op2 != ul_f("op1") % f_l_op2) || (ul_f("op1") % f_l_op2 != ul_f("op1") % d_l_op2) || ((decimal)(ul_f("op1") % d_l_op2) != ul_f("op1") % m_l_op2) || (ul_f("op1") % m_l_op2 != ul_f("op1") % (ulong)i_l_op2) || (ul_f("op1") % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 17 failed"); passed = false; } if ((ul_f("op1") % (ulong)s_i_s_op2 != ul_f("op1") % s_ui_s_op2) || (ul_f("op1") % s_ui_s_op2 != ul_f("op1") % (ulong)s_l_s_op2) || (ul_f("op1") % (ulong)s_l_s_op2 != ul_f("op1") % s_ul_s_op2) || (ul_f("op1") % s_ul_s_op2 != ul_f("op1") % s_f_s_op2) || (ul_f("op1") % s_f_s_op2 != ul_f("op1") % s_d_s_op2) || ((decimal)(ul_f("op1") % s_d_s_op2) != ul_f("op1") % s_m_s_op2) || (ul_f("op1") % s_m_s_op2 != ul_f("op1") % (ulong)s_i_s_op2) || (ul_f("op1") % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 18 failed"); passed = false; } if ((ul_f("op1") % (ulong)ul_f("op2") != ul_f("op1") % ul_f("op2")) || (ul_f("op1") % ul_f("op2") != ul_f("op1") % (ulong)ul_f("op2")) || (ul_f("op1") % (ulong)ul_f("op2") != ul_f("op1") % ul_f("op2")) || (ul_f("op1") % ul_f("op2") != ul_f("op1") % ul_f("op2")) || (ul_f("op1") % ul_f("op2") != ul_f("op1") % ul_f("op2")) || ((decimal)(ul_f("op1") % ul_f("op2")) != ul_f("op1") % ul_f("op2")) || (ul_f("op1") % ul_f("op2") != ul_f("op1") % (ulong)ul_f("op2")) || (ul_f("op1") % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 19 failed"); passed = false; } if ((ul_f("op1") % (ulong)cl1.i_cl_op2 != ul_f("op1") % cl1.ui_cl_op2) || (ul_f("op1") % cl1.ui_cl_op2 != ul_f("op1") % (ulong)cl1.l_cl_op2) || (ul_f("op1") % (ulong)cl1.l_cl_op2 != ul_f("op1") % cl1.ul_cl_op2) || (ul_f("op1") % cl1.ul_cl_op2 != ul_f("op1") % cl1.f_cl_op2) || (ul_f("op1") % cl1.f_cl_op2 != ul_f("op1") % cl1.d_cl_op2) || ((decimal)(ul_f("op1") % cl1.d_cl_op2) != ul_f("op1") % cl1.m_cl_op2) || (ul_f("op1") % cl1.m_cl_op2 != ul_f("op1") % (ulong)cl1.i_cl_op2) || (ul_f("op1") % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 20 failed"); passed = false; } if ((ul_f("op1") % (ulong)vt1.i_vt_op2 != ul_f("op1") % vt1.ui_vt_op2) || (ul_f("op1") % vt1.ui_vt_op2 != ul_f("op1") % (ulong)vt1.l_vt_op2) || (ul_f("op1") % (ulong)vt1.l_vt_op2 != ul_f("op1") % vt1.ul_vt_op2) || (ul_f("op1") % vt1.ul_vt_op2 != ul_f("op1") % vt1.f_vt_op2) || (ul_f("op1") % vt1.f_vt_op2 != ul_f("op1") % vt1.d_vt_op2) || ((decimal)(ul_f("op1") % vt1.d_vt_op2) != ul_f("op1") % vt1.m_vt_op2) || (ul_f("op1") % vt1.m_vt_op2 != ul_f("op1") % (ulong)vt1.i_vt_op2) || (ul_f("op1") % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 21 failed"); passed = false; } if ((ul_f("op1") % (ulong)i_arr1d_op2[0] != ul_f("op1") % ui_arr1d_op2[0]) || (ul_f("op1") % ui_arr1d_op2[0] != ul_f("op1") % (ulong)l_arr1d_op2[0]) || (ul_f("op1") % (ulong)l_arr1d_op2[0] != ul_f("op1") % ul_arr1d_op2[0]) || (ul_f("op1") % ul_arr1d_op2[0] != ul_f("op1") % f_arr1d_op2[0]) || (ul_f("op1") % f_arr1d_op2[0] != ul_f("op1") % d_arr1d_op2[0]) || ((decimal)(ul_f("op1") % d_arr1d_op2[0]) != ul_f("op1") % m_arr1d_op2[0]) || (ul_f("op1") % m_arr1d_op2[0] != ul_f("op1") % (ulong)i_arr1d_op2[0]) || (ul_f("op1") % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 22 failed"); passed = false; } if ((ul_f("op1") % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % ui_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % ul_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % f_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % f_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(ul_f("op1") % d_arr2d_op2[index[0, 1], index[1, 0]]) != ul_f("op1") % m_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % m_arr2d_op2[index[0, 1], index[1, 0]] != ul_f("op1") % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_f("op1") % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 23 failed"); passed = false; } if ((ul_f("op1") % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(ul_f("op1") % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != ul_f("op1") % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_f("op1") % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_f("op1") % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 24 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)i_l_op2 != cl1.ul_cl_op1 % ui_l_op2) || (cl1.ul_cl_op1 % ui_l_op2 != cl1.ul_cl_op1 % (ulong)l_l_op2) || (cl1.ul_cl_op1 % (ulong)l_l_op2 != cl1.ul_cl_op1 % ul_l_op2) || (cl1.ul_cl_op1 % ul_l_op2 != cl1.ul_cl_op1 % f_l_op2) || (cl1.ul_cl_op1 % f_l_op2 != cl1.ul_cl_op1 % d_l_op2) || ((decimal)(cl1.ul_cl_op1 % d_l_op2) != cl1.ul_cl_op1 % m_l_op2) || (cl1.ul_cl_op1 % m_l_op2 != cl1.ul_cl_op1 % (ulong)i_l_op2) || (cl1.ul_cl_op1 % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 25 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)s_i_s_op2 != cl1.ul_cl_op1 % s_ui_s_op2) || (cl1.ul_cl_op1 % s_ui_s_op2 != cl1.ul_cl_op1 % (ulong)s_l_s_op2) || (cl1.ul_cl_op1 % (ulong)s_l_s_op2 != cl1.ul_cl_op1 % s_ul_s_op2) || (cl1.ul_cl_op1 % s_ul_s_op2 != cl1.ul_cl_op1 % s_f_s_op2) || (cl1.ul_cl_op1 % s_f_s_op2 != cl1.ul_cl_op1 % s_d_s_op2) || ((decimal)(cl1.ul_cl_op1 % s_d_s_op2) != cl1.ul_cl_op1 % s_m_s_op2) || (cl1.ul_cl_op1 % s_m_s_op2 != cl1.ul_cl_op1 % (ulong)s_i_s_op2) || (cl1.ul_cl_op1 % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 26 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)ul_f("op2") != cl1.ul_cl_op1 % ul_f("op2")) || (cl1.ul_cl_op1 % ul_f("op2") != cl1.ul_cl_op1 % (ulong)ul_f("op2")) || (cl1.ul_cl_op1 % (ulong)ul_f("op2") != cl1.ul_cl_op1 % ul_f("op2")) || (cl1.ul_cl_op1 % ul_f("op2") != cl1.ul_cl_op1 % ul_f("op2")) || (cl1.ul_cl_op1 % ul_f("op2") != cl1.ul_cl_op1 % ul_f("op2")) || ((decimal)(cl1.ul_cl_op1 % ul_f("op2")) != cl1.ul_cl_op1 % ul_f("op2")) || (cl1.ul_cl_op1 % ul_f("op2") != cl1.ul_cl_op1 % (ulong)ul_f("op2")) || (cl1.ul_cl_op1 % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 27 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)cl1.i_cl_op2 != cl1.ul_cl_op1 % cl1.ui_cl_op2) || (cl1.ul_cl_op1 % cl1.ui_cl_op2 != cl1.ul_cl_op1 % (ulong)cl1.l_cl_op2) || (cl1.ul_cl_op1 % (ulong)cl1.l_cl_op2 != cl1.ul_cl_op1 % cl1.ul_cl_op2) || (cl1.ul_cl_op1 % cl1.ul_cl_op2 != cl1.ul_cl_op1 % cl1.f_cl_op2) || (cl1.ul_cl_op1 % cl1.f_cl_op2 != cl1.ul_cl_op1 % cl1.d_cl_op2) || ((decimal)(cl1.ul_cl_op1 % cl1.d_cl_op2) != cl1.ul_cl_op1 % cl1.m_cl_op2) || (cl1.ul_cl_op1 % cl1.m_cl_op2 != cl1.ul_cl_op1 % (ulong)cl1.i_cl_op2) || (cl1.ul_cl_op1 % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 28 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)vt1.i_vt_op2 != cl1.ul_cl_op1 % vt1.ui_vt_op2) || (cl1.ul_cl_op1 % vt1.ui_vt_op2 != cl1.ul_cl_op1 % (ulong)vt1.l_vt_op2) || (cl1.ul_cl_op1 % (ulong)vt1.l_vt_op2 != cl1.ul_cl_op1 % vt1.ul_vt_op2) || (cl1.ul_cl_op1 % vt1.ul_vt_op2 != cl1.ul_cl_op1 % vt1.f_vt_op2) || (cl1.ul_cl_op1 % vt1.f_vt_op2 != cl1.ul_cl_op1 % vt1.d_vt_op2) || ((decimal)(cl1.ul_cl_op1 % vt1.d_vt_op2) != cl1.ul_cl_op1 % vt1.m_vt_op2) || (cl1.ul_cl_op1 % vt1.m_vt_op2 != cl1.ul_cl_op1 % (ulong)vt1.i_vt_op2) || (cl1.ul_cl_op1 % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 29 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)i_arr1d_op2[0] != cl1.ul_cl_op1 % ui_arr1d_op2[0]) || (cl1.ul_cl_op1 % ui_arr1d_op2[0] != cl1.ul_cl_op1 % (ulong)l_arr1d_op2[0]) || (cl1.ul_cl_op1 % (ulong)l_arr1d_op2[0] != cl1.ul_cl_op1 % ul_arr1d_op2[0]) || (cl1.ul_cl_op1 % ul_arr1d_op2[0] != cl1.ul_cl_op1 % f_arr1d_op2[0]) || (cl1.ul_cl_op1 % f_arr1d_op2[0] != cl1.ul_cl_op1 % d_arr1d_op2[0]) || ((decimal)(cl1.ul_cl_op1 % d_arr1d_op2[0]) != cl1.ul_cl_op1 % m_arr1d_op2[0]) || (cl1.ul_cl_op1 % m_arr1d_op2[0] != cl1.ul_cl_op1 % (ulong)i_arr1d_op2[0]) || (cl1.ul_cl_op1 % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 30 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(cl1.ul_cl_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) != cl1.ul_cl_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != cl1.ul_cl_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (cl1.ul_cl_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 31 failed"); passed = false; } if ((cl1.ul_cl_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(cl1.ul_cl_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != cl1.ul_cl_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != cl1.ul_cl_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (cl1.ul_cl_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 32 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)i_l_op2 != vt1.ul_vt_op1 % ui_l_op2) || (vt1.ul_vt_op1 % ui_l_op2 != vt1.ul_vt_op1 % (ulong)l_l_op2) || (vt1.ul_vt_op1 % (ulong)l_l_op2 != vt1.ul_vt_op1 % ul_l_op2) || (vt1.ul_vt_op1 % ul_l_op2 != vt1.ul_vt_op1 % f_l_op2) || (vt1.ul_vt_op1 % f_l_op2 != vt1.ul_vt_op1 % d_l_op2) || ((decimal)(vt1.ul_vt_op1 % d_l_op2) != vt1.ul_vt_op1 % m_l_op2) || (vt1.ul_vt_op1 % m_l_op2 != vt1.ul_vt_op1 % (ulong)i_l_op2) || (vt1.ul_vt_op1 % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 33 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)s_i_s_op2 != vt1.ul_vt_op1 % s_ui_s_op2) || (vt1.ul_vt_op1 % s_ui_s_op2 != vt1.ul_vt_op1 % (ulong)s_l_s_op2) || (vt1.ul_vt_op1 % (ulong)s_l_s_op2 != vt1.ul_vt_op1 % s_ul_s_op2) || (vt1.ul_vt_op1 % s_ul_s_op2 != vt1.ul_vt_op1 % s_f_s_op2) || (vt1.ul_vt_op1 % s_f_s_op2 != vt1.ul_vt_op1 % s_d_s_op2) || ((decimal)(vt1.ul_vt_op1 % s_d_s_op2) != vt1.ul_vt_op1 % s_m_s_op2) || (vt1.ul_vt_op1 % s_m_s_op2 != vt1.ul_vt_op1 % (ulong)s_i_s_op2) || (vt1.ul_vt_op1 % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 34 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)ul_f("op2") != vt1.ul_vt_op1 % ul_f("op2")) || (vt1.ul_vt_op1 % ul_f("op2") != vt1.ul_vt_op1 % (ulong)ul_f("op2")) || (vt1.ul_vt_op1 % (ulong)ul_f("op2") != vt1.ul_vt_op1 % ul_f("op2")) || (vt1.ul_vt_op1 % ul_f("op2") != vt1.ul_vt_op1 % ul_f("op2")) || (vt1.ul_vt_op1 % ul_f("op2") != vt1.ul_vt_op1 % ul_f("op2")) || ((decimal)(vt1.ul_vt_op1 % ul_f("op2")) != vt1.ul_vt_op1 % ul_f("op2")) || (vt1.ul_vt_op1 % ul_f("op2") != vt1.ul_vt_op1 % (ulong)ul_f("op2")) || (vt1.ul_vt_op1 % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 35 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)cl1.i_cl_op2 != vt1.ul_vt_op1 % cl1.ui_cl_op2) || (vt1.ul_vt_op1 % cl1.ui_cl_op2 != vt1.ul_vt_op1 % (ulong)cl1.l_cl_op2) || (vt1.ul_vt_op1 % (ulong)cl1.l_cl_op2 != vt1.ul_vt_op1 % cl1.ul_cl_op2) || (vt1.ul_vt_op1 % cl1.ul_cl_op2 != vt1.ul_vt_op1 % cl1.f_cl_op2) || (vt1.ul_vt_op1 % cl1.f_cl_op2 != vt1.ul_vt_op1 % cl1.d_cl_op2) || ((decimal)(vt1.ul_vt_op1 % cl1.d_cl_op2) != vt1.ul_vt_op1 % cl1.m_cl_op2) || (vt1.ul_vt_op1 % cl1.m_cl_op2 != vt1.ul_vt_op1 % (ulong)cl1.i_cl_op2) || (vt1.ul_vt_op1 % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 36 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)vt1.i_vt_op2 != vt1.ul_vt_op1 % vt1.ui_vt_op2) || (vt1.ul_vt_op1 % vt1.ui_vt_op2 != vt1.ul_vt_op1 % (ulong)vt1.l_vt_op2) || (vt1.ul_vt_op1 % (ulong)vt1.l_vt_op2 != vt1.ul_vt_op1 % vt1.ul_vt_op2) || (vt1.ul_vt_op1 % vt1.ul_vt_op2 != vt1.ul_vt_op1 % vt1.f_vt_op2) || (vt1.ul_vt_op1 % vt1.f_vt_op2 != vt1.ul_vt_op1 % vt1.d_vt_op2) || ((decimal)(vt1.ul_vt_op1 % vt1.d_vt_op2) != vt1.ul_vt_op1 % vt1.m_vt_op2) || (vt1.ul_vt_op1 % vt1.m_vt_op2 != vt1.ul_vt_op1 % (ulong)vt1.i_vt_op2) || (vt1.ul_vt_op1 % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 37 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)i_arr1d_op2[0] != vt1.ul_vt_op1 % ui_arr1d_op2[0]) || (vt1.ul_vt_op1 % ui_arr1d_op2[0] != vt1.ul_vt_op1 % (ulong)l_arr1d_op2[0]) || (vt1.ul_vt_op1 % (ulong)l_arr1d_op2[0] != vt1.ul_vt_op1 % ul_arr1d_op2[0]) || (vt1.ul_vt_op1 % ul_arr1d_op2[0] != vt1.ul_vt_op1 % f_arr1d_op2[0]) || (vt1.ul_vt_op1 % f_arr1d_op2[0] != vt1.ul_vt_op1 % d_arr1d_op2[0]) || ((decimal)(vt1.ul_vt_op1 % d_arr1d_op2[0]) != vt1.ul_vt_op1 % m_arr1d_op2[0]) || (vt1.ul_vt_op1 % m_arr1d_op2[0] != vt1.ul_vt_op1 % (ulong)i_arr1d_op2[0]) || (vt1.ul_vt_op1 % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 38 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % ui_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % ul_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % f_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % f_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(vt1.ul_vt_op1 % d_arr2d_op2[index[0, 1], index[1, 0]]) != vt1.ul_vt_op1 % m_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % m_arr2d_op2[index[0, 1], index[1, 0]] != vt1.ul_vt_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (vt1.ul_vt_op1 % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 39 failed"); passed = false; } if ((vt1.ul_vt_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(vt1.ul_vt_op1 % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != vt1.ul_vt_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != vt1.ul_vt_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (vt1.ul_vt_op1 % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 40 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)i_l_op2 != ul_arr1d_op1[1] % ui_l_op2) || (ul_arr1d_op1[1] % ui_l_op2 != ul_arr1d_op1[1] % (ulong)l_l_op2) || (ul_arr1d_op1[1] % (ulong)l_l_op2 != ul_arr1d_op1[1] % ul_l_op2) || (ul_arr1d_op1[1] % ul_l_op2 != ul_arr1d_op1[1] % f_l_op2) || (ul_arr1d_op1[1] % f_l_op2 != ul_arr1d_op1[1] % d_l_op2) || ((decimal)(ul_arr1d_op1[1] % d_l_op2) != ul_arr1d_op1[1] % m_l_op2) || (ul_arr1d_op1[1] % m_l_op2 != ul_arr1d_op1[1] % (ulong)i_l_op2) || (ul_arr1d_op1[1] % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 41 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)s_i_s_op2 != ul_arr1d_op1[1] % s_ui_s_op2) || (ul_arr1d_op1[1] % s_ui_s_op2 != ul_arr1d_op1[1] % (ulong)s_l_s_op2) || (ul_arr1d_op1[1] % (ulong)s_l_s_op2 != ul_arr1d_op1[1] % s_ul_s_op2) || (ul_arr1d_op1[1] % s_ul_s_op2 != ul_arr1d_op1[1] % s_f_s_op2) || (ul_arr1d_op1[1] % s_f_s_op2 != ul_arr1d_op1[1] % s_d_s_op2) || ((decimal)(ul_arr1d_op1[1] % s_d_s_op2) != ul_arr1d_op1[1] % s_m_s_op2) || (ul_arr1d_op1[1] % s_m_s_op2 != ul_arr1d_op1[1] % (ulong)s_i_s_op2) || (ul_arr1d_op1[1] % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 42 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)ul_f("op2") != ul_arr1d_op1[1] % ul_f("op2")) || (ul_arr1d_op1[1] % ul_f("op2") != ul_arr1d_op1[1] % (ulong)ul_f("op2")) || (ul_arr1d_op1[1] % (ulong)ul_f("op2") != ul_arr1d_op1[1] % ul_f("op2")) || (ul_arr1d_op1[1] % ul_f("op2") != ul_arr1d_op1[1] % ul_f("op2")) || (ul_arr1d_op1[1] % ul_f("op2") != ul_arr1d_op1[1] % ul_f("op2")) || ((decimal)(ul_arr1d_op1[1] % ul_f("op2")) != ul_arr1d_op1[1] % ul_f("op2")) || (ul_arr1d_op1[1] % ul_f("op2") != ul_arr1d_op1[1] % (ulong)ul_f("op2")) || (ul_arr1d_op1[1] % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 43 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)cl1.i_cl_op2 != ul_arr1d_op1[1] % cl1.ui_cl_op2) || (ul_arr1d_op1[1] % cl1.ui_cl_op2 != ul_arr1d_op1[1] % (ulong)cl1.l_cl_op2) || (ul_arr1d_op1[1] % (ulong)cl1.l_cl_op2 != ul_arr1d_op1[1] % cl1.ul_cl_op2) || (ul_arr1d_op1[1] % cl1.ul_cl_op2 != ul_arr1d_op1[1] % cl1.f_cl_op2) || (ul_arr1d_op1[1] % cl1.f_cl_op2 != ul_arr1d_op1[1] % cl1.d_cl_op2) || ((decimal)(ul_arr1d_op1[1] % cl1.d_cl_op2) != ul_arr1d_op1[1] % cl1.m_cl_op2) || (ul_arr1d_op1[1] % cl1.m_cl_op2 != ul_arr1d_op1[1] % (ulong)cl1.i_cl_op2) || (ul_arr1d_op1[1] % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 44 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)vt1.i_vt_op2 != ul_arr1d_op1[1] % vt1.ui_vt_op2) || (ul_arr1d_op1[1] % vt1.ui_vt_op2 != ul_arr1d_op1[1] % (ulong)vt1.l_vt_op2) || (ul_arr1d_op1[1] % (ulong)vt1.l_vt_op2 != ul_arr1d_op1[1] % vt1.ul_vt_op2) || (ul_arr1d_op1[1] % vt1.ul_vt_op2 != ul_arr1d_op1[1] % vt1.f_vt_op2) || (ul_arr1d_op1[1] % vt1.f_vt_op2 != ul_arr1d_op1[1] % vt1.d_vt_op2) || ((decimal)(ul_arr1d_op1[1] % vt1.d_vt_op2) != ul_arr1d_op1[1] % vt1.m_vt_op2) || (ul_arr1d_op1[1] % vt1.m_vt_op2 != ul_arr1d_op1[1] % (ulong)vt1.i_vt_op2) || (ul_arr1d_op1[1] % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 45 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)i_arr1d_op2[0] != ul_arr1d_op1[1] % ui_arr1d_op2[0]) || (ul_arr1d_op1[1] % ui_arr1d_op2[0] != ul_arr1d_op1[1] % (ulong)l_arr1d_op2[0]) || (ul_arr1d_op1[1] % (ulong)l_arr1d_op2[0] != ul_arr1d_op1[1] % ul_arr1d_op2[0]) || (ul_arr1d_op1[1] % ul_arr1d_op2[0] != ul_arr1d_op1[1] % f_arr1d_op2[0]) || (ul_arr1d_op1[1] % f_arr1d_op2[0] != ul_arr1d_op1[1] % d_arr1d_op2[0]) || ((decimal)(ul_arr1d_op1[1] % d_arr1d_op2[0]) != ul_arr1d_op1[1] % m_arr1d_op2[0]) || (ul_arr1d_op1[1] % m_arr1d_op2[0] != ul_arr1d_op1[1] % (ulong)i_arr1d_op2[0]) || (ul_arr1d_op1[1] % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 46 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % ui_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % ul_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % f_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(ul_arr1d_op1[1] % d_arr2d_op2[index[0, 1], index[1, 0]]) != ul_arr1d_op1[1] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % m_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr1d_op1[1] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr1d_op1[1] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 47 failed"); passed = false; } if ((ul_arr1d_op1[1] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(ul_arr1d_op1[1] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != ul_arr1d_op1[1] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr1d_op1[1] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr1d_op1[1] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 48 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % f_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % f_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % d_l_op2) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % d_l_op2) != ul_arr2d_op1[index[0, 1], index[1, 0]] % m_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % m_l_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_l_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 49 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)s_i_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % s_ui_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % s_ui_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)s_l_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)s_l_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % s_ul_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % s_ul_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % s_f_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % s_f_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % s_d_s_op2) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % s_d_s_op2) != ul_arr2d_op1[index[0, 1], index[1, 0]] % s_m_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % s_m_s_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)s_i_s_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 50 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_f("op2") != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)ul_f("op2")) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 51 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)cl1.i_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ui_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ui_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)cl1.l_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)cl1.l_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ul_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.ul_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.f_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.f_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.d_cl_op2) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.d_cl_op2) != ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.m_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % cl1.m_cl_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)cl1.i_cl_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 52 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)vt1.i_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ui_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ui_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)vt1.l_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)vt1.l_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ul_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.ul_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.f_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.f_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.d_vt_op2) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.d_vt_op2) != ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.m_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % vt1.m_vt_op2 != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)vt1.i_vt_op2) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 53 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr1d_op2[0]) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr1d_op2[0]) != ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr1d_op2[0] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr1d_op2[0]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 54 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr2d_op2[index[0, 1], index[1, 0]]) != ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 55 failed"); passed = false; } if ((ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(ul_arr2d_op1[index[0, 1], index[1, 0]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr2d_op1[index[0, 1], index[1, 0]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 56 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_l_op2) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_l_op2) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_l_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_l_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_l_op2 != 2)) { Console.WriteLine("testcase 57 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)s_i_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ui_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ui_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)s_l_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)s_l_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ul_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_ul_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_f_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_f_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_d_s_op2) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_d_s_op2) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_m_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % s_m_s_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)s_i_s_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)s_i_s_op2 != 2)) { Console.WriteLine("testcase 58 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_f("op2") != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)ul_f("op2")) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)ul_f("op2") != 2)) { Console.WriteLine("testcase 59 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)cl1.i_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ui_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ui_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)cl1.l_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)cl1.l_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ul_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.ul_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.f_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.f_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.d_cl_op2) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.d_cl_op2) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.m_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % cl1.m_cl_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)cl1.i_cl_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)cl1.i_cl_op2 != 2)) { Console.WriteLine("testcase 60 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)vt1.i_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ui_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ui_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)vt1.l_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)vt1.l_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ul_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.ul_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.f_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.f_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.d_vt_op2) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.d_vt_op2) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.m_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % vt1.m_vt_op2 != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)vt1.i_vt_op2) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)vt1.i_vt_op2 != 2)) { Console.WriteLine("testcase 61 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr1d_op2[0]) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr1d_op2[0]) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr1d_op2[0] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr1d_op2[0]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr1d_op2[0] != 2)) { Console.WriteLine("testcase 62 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr2d_op2[index[0, 1], index[1, 0]]) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr2d_op2[index[0, 1], index[1, 0]]) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr2d_op2[index[0, 1], index[1, 0]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr2d_op2[index[0, 1], index[1, 0]] != 2)) { Console.WriteLine("testcase 63 failed"); passed = false; } if ((ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ui_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)l_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % ul_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % f_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) || ((decimal)(ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % d_arr3d_op2[index[0, 0], 0, index[1, 1]]) != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % m_arr3d_op2[index[0, 0], 0, index[1, 1]] != ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]]) || (ul_arr3d_op1[index[0, 0], 0, index[1, 1]] % (ulong)i_arr3d_op2[index[0, 0], 0, index[1, 1]] != 2)) { Console.WriteLine("testcase 64 failed"); passed = false; } } if (!passed) { Console.WriteLine("FAILED"); return 1; } else { Console.WriteLine("PASSED"); return 100; } }
public static int Main(string[] args) { bool passed; string teststr = ""; int len = 0; if (args.Length != 0) { teststr = args[0]; len = teststr.Length; } else { //construct random string with random length len = rand.Next(50); teststr = randomUnicodeString(len); } Console.WriteLine("Test string is {0}", teststr); String str2 = ""; CL cl1 = new CL(); VT vt1; str1 = str2 = cl1.str = vt1.str = teststr; String[] str1darr = new String[len]; for (int j = 0; j < len; j++) str1darr[j] = Convert.ToString(teststr[j]); char b0, b1, b2, b3, b4; try { passed = false; b0 = cl1.str[len]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b1 = str1[len]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b2 = str2[len]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b3 = vt1.str[len]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b4 = Convert.ToChar(str1darr[len]); } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b0 = cl1.str[-1]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b1 = str1[-1]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b2 = str2[-1]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b3 = vt1.str[-1]; } catch (IndexOutOfRangeException) { passed = true; } try { passed = false; b4 = Convert.ToChar(str1darr[-1]); } catch (IndexOutOfRangeException) { passed = true; } int i; while (len != 0) { i = rand.Next(0, len); b0 = cl1.str[i]; b1 = str1[i]; b2 = str2[i]; b3 = vt1.str[i]; b4 = Convert.ToChar(str1darr[i]); if ((b0 != b1) || (b1 != b2) || (b2 != b3) || (b3 != b4)) passed = false; len /= 2; } Console.WriteLine(); if (!passed) { Console.WriteLine("FAILED"); Console.WriteLine("Use the following command to repro:"); Console.WriteLine("straccess3.exe {0}", teststr); return 1; } else { Console.WriteLine("PASSED"); return 100; } }