Determining if a data type is compound or not with IsCompound

ID: 87

				
					using uCalcSoftware;

var uc = new uCalc();
Console.WriteLine(uc.DataTypeOf("2 * (3 + 4)").IsCompound);
Console.WriteLine(uc.DataTypeOf(" 'Hello ' + 'world!' ").IsCompound);
Console.WriteLine(uc.DataTypeOf("3 + 4 * #i").IsCompound);
Console.WriteLine(uc.DataTypeOf(BuiltInType.String).IsCompound);
Console.WriteLine(uc.DataTypeOf("Bool").IsCompound);
				
			
False
True
True
True
False
				
					#include <iostream>
#include "uCalc.h"

using namespace std;
using namespace uCalcSoftware;

#define tf(IsTrue) ((IsTrue) ? "True" : "False")

int main() {
   uCalc uc;
   cout << tf(uc.DataTypeOf("2 * (3 + 4)").IsCompound()) << endl;
   cout << tf(uc.DataTypeOf(" 'Hello ' + 'world!' ").IsCompound()) << endl;
   cout << tf(uc.DataTypeOf("3 + 4 * #i").IsCompound()) << endl;
   cout << tf(uc.DataTypeOf(BuiltInType::String).IsCompound()) << endl;
   cout << tf(uc.DataTypeOf("Bool").IsCompound()) << endl;
}
				
			
False
True
True
True
False
				
					Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Console.WriteLine(uc.DataTypeOf("2 * (3 + 4)").IsCompound)
      Console.WriteLine(uc.DataTypeOf(" 'Hello ' + 'world!' ").IsCompound)
      Console.WriteLine(uc.DataTypeOf("3 + 4 * #i").IsCompound)
      Console.WriteLine(uc.DataTypeOf(BuiltInType.String).IsCompound)
      Console.WriteLine(uc.DataTypeOf("Bool").IsCompound)
   End Sub
End Module
				
			
False
True
True
True
False