fork download
  1. Imports System
  2.  
  3. Public Class Test
  4. Public Shared Sub Main()
  5. Dim n As Integer
  6. n = Console.ReadLine
  7. Do While n <> 42
  8. System.Console.WriteLine(n)
  9. n = Console.ReadLine
  10. Loop
  11. End Sub
  12. End Class
Runtime error #stdin #stdout #stderr 0.05s 28200KB
stdin
void substitution_encrypt()
{
    char s[10] = "Hello!", t[10] = "";
 
    // 建立轉換表格
    char table[128];
    for (int i=0; i<128; i++) table[i] = i;
    table['!'] = 'w';
    table['H'] = 'Y';
 
    // 開始轉換
    int n;
    for (n=0; s[n] != '\0'; n++)
        t[n] = table[ s[n] ];
    t[n] = '\0';
}
 
void substitution_decrypt()
{
    // 省略
}
 
void transposition_encrypt()
{
    char s[10] = "Hello!", t[10] = "";
 
    // 建立轉換表格
    int table[50];
    for (int i=0; i<50; ++i) table[i] = i;
    table[2] = 3;
    table[3] = 5;
    table[5] = 2;
 
    // 開始轉換
    int n;
    for (n=0; s[n] != '\0'; n++)
        t[n] = table[ s[n] ];
    t[n] = '\0';
}
 
void transposition_decrypt()
{
    // 省略
}
stdout
Standard output is empty
stderr
Unhandled Exception:
System.InvalidCastException: Conversion from string "void substitution_encrypt()" to type 'Integer' is not valid. ---> System.FormatException: Input string was not in the correct format
  at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0 
  at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString (System.String Value) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString (System.String Value) [0x00000] in <filename unknown>:0 
  at Microsoft.VisualBasic.CompilerServices.Conversions.ToInteger (System.String Value) [0x00000] in <filename unknown>:0 
  at Test.Main () [0x00000] in <filename unknown>:0 
[ERROR] FATAL UNHANDLED EXCEPTION: System.InvalidCastException: Conversion from string "void substitution_encrypt()" to type 'Integer' is not valid. ---> System.FormatException: Input string was not in the correct format
  at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0 
  at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString (System.String Value) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString (System.String Value) [0x00000] in <filename unknown>:0 
  at Microsoft.VisualBasic.CompilerServices.Conversions.ToInteger (System.String Value) [0x00000] in <filename unknown>:0 
  at Test.Main () [0x00000] in <filename unknown>:0