# Well, that was satisfying ... "Hello World!" with .Net 6

**URL:** https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762
**Category:** C#
**Tags:** net
**Created:** [November 28, 2021, 11:25pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762 "2021-11-28T23:25:58Z")
**Posts on this page:** 14
**Page:** 1

<div class="post-metadata">

### Author: ![chikega](https://talk.remobjects.com/user_avatar/talk.remobjects.com/chikega/32/15211_2.png) [@chikega](https://talk.remobjects.com/u/chikega)
#### Post date: [November 28, 2021, 11:25pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/1 "2021-11-28T23:25:58Z")

</div>

… slashing all the boiler template code 🤓

```auto
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;

//namespace Cons_CS_NetCore
//{
    //static class Program
    //{
        //public static Int32 Main(string[] args)
        //{
            //Console.WriteLine("The magic happens here.");
            //return 0;
        //}
    //}
//}

Console.WriteLine("Hello World!");

```

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [November 29, 2021, 2:53pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/2 "2021-11-29T14:53:58Z")

</div>

Should work for all platforms, FWIW (older/Classic .NET, as well as non-.NET), as well. 🙃

---

<div class="post-metadata">

### Author: ![Theo69](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/t/35a633/32.png) [@Theo69](https://talk.remobjects.com/u/Theo69)
#### Post date: [November 30, 2021, 1:26pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/3 "2021-11-30T13:26:34Z")

</div>

Is it difficult to add that to the other languages?

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [November 30, 2021, 1:28pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/4 "2021-11-30T13:28:46Z")

</div>

> [@Theo69](#):
>
> Is it difficult to add that to the other languages?

Should be easy. Swift always supported this, and Oxygene has `begin`/`end.` so doesn’t really need this. But adding it to Mercury should be simple; i’ll log.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [November 30, 2021, 1:32pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/5 "2021-11-30T13:32:07Z")

</div>

Logged as [bugs://E25540](https://www.remobjects.com/portal/bugs/?id=E25540).

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [November 30, 2021, 2:04pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/6 "2021-11-30T14:04:53Z")

</div>

Could begin end be extended to support a task ?

```auto
begin
  await Task.Delay(TimeSpan.FromSeconds(2));
end.

```

With this I get await is not supported here.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [November 30, 2021, 5:36pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/7 "2021-11-30T17:36:45Z")

</div>

Logged as [bugs://E25541](https://www.remobjects.com/portal/bugs/?id=E25541).

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [November 30, 2021, 7:48pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/8 "2021-11-30T19:48:59Z")

</div>

[bugs://E25541](https://www.remobjects.com/portal/bugs/?id=E25541) was closed as fixed.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 1, 2021, 3:54am UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/9 "2021-12-01T03:54:08Z")

</div>

It builds but doesn’t seem to wait

[ClassLessApplication.zip](https://talk.remobjects.com/uploads/short-url/bSRLkMSgtF3ypgfGPzvcqwL3YZW.zip) (130.7 KB)

I just see ‘start’ on the console.

These are the same arent they ?

````auto
namespace ClassLessApplication;

interface

uses
  System.Diagnostics;

implementation

begin
  Console.WriteLine('Start');
  var sw := Stopwatch.StartNew;
  await Task.Delay(TimeSpan.FromSeconds(2));
  sw.Stop;
  Console.WriteLine(sw.ElapsedMilliseconds);
  Console.WriteLine('Stop');
end.```

c#

````

using System.Diagnostics;

var sw = Stopwatch.StartNew();

await Task.Delay(TimeSpan.FromSeconds(2));

sw.Stop();

Console.WriteLine(sw.ElapsedMilliseconds);

```auto

```

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [December 1, 2021, 12:01pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/10 "2021-12-01T12:01:51Z")

</div>

[bugs://E25540](https://www.remobjects.com/portal/bugs/?id=E25540) was closed as fixed.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [December 1, 2021, 12:11pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/11 "2021-12-01T12:11:29Z")

</div>

[bugs://E25541](https://www.remobjects.com/portal/bugs/?id=E25541) was reopened.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [December 1, 2021, 12:23pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/12 "2021-12-01T12:23:33Z")

</div>

[bugs://E25541](https://www.remobjects.com/portal/bugs/?id=E25541) was closed as fixed.

---

<div class="post-metadata">

### Author: ![ck](https://talk.remobjects.com/user_avatar/talk.remobjects.com/ck/32/8740_2.png) [@ck](https://talk.remobjects.com/u/ck)
#### Post date: [December 1, 2021, 12:23pm UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/13 "2021-12-01T12:23:53Z")

</div>

My apologies I overlooked 1 change that caused this. Properly fixed now.

---

<div class="post-metadata">

### Author: ![chikega](https://talk.remobjects.com/user_avatar/talk.remobjects.com/chikega/32/15211_2.png) [@chikega](https://talk.remobjects.com/u/chikega)
#### Post date: [March 18, 2022, 3:16am UTC](https://talk.remobjects.com/t/well-that-was-satisfying-hello-world-with-net-6/25762/14 "2022-03-18T03:16:04Z")

</div>

> [@mh](#):
>
> Should work for all platforms, FWIW (older/Classic .NET, as well as non-.NET), as well.

You’re right, the shortest Oxygene program I’ve written yet! Works in both .Net 6.0 and Classic .Net 🤓

```auto
namespace NetCoreTestOxy;

begin
  writeLn('The magic happens here.');
end.

```
