Whoever wrote this forum post need to get fired

im just now learning lua never used it and it give me this. local hello_world = {}

function hello_world.hello()
return ‘Goodbye, Mars!’
end

return hello_world
strong text

it give me nothing to go off of and how to learn to do it, it just says The classical introductory exercise. Just says i went to youtube and no one shows how to do it,

“Hello, World!”.
“Hello, World!” is the traditional first program for beginning programming in a new language or environment.

The objectives are simple:

  • Write a function that returns the string “Hello, World!”.
  • Run the test suite and make sure that it succeeds.
  • Submit your solution and check it at the website.

If everything goes well, you will be ready to fetch your first real exercise.

Tracks are built by unpaid volunteers. They can’t be fired :smiley:

The stub gives you a lot to go off of! A working example of a Lua function which returns a string, 'Goodbye, Mars!'. Just like in all the other tracks, you need to modify this working function which returns one string to, instead, return another string. The trick to accomplishing this probably lies in modifying that string.

Does that help?

i had to modify hello mars and nothing else

i am so dumb

It’s a learning exercise :slight_smile: The expectation is that people come into it not knowing how functions work, read the code, and learn about a simple function structure. People who haven’t yet learned something aren’t dumb; they just haven’t yet learned that thing! And learning is the whole point here! You’re not dumb – you’re learning and using Exercism for its intended design.

Is the volunteer allowed back into the office now? :smiley:

3 Likes

no sorry, i still cant figure it out.

function hello_world.hello()
return (‘Hello,World’)

its still wrong

i got this
Expected objects to be equal.
Passed in:
(string) ‘Hello, World’
Expected:
(string) ‘Hello, World!’

and this

local result = hello_world.hello()
assert.are.equal('Hello, World!', result)

NVM I forgot the ! im sorry to waste your time i completed it

the volunteer is allowed back into the office now

I updated the forum thread title for you :wink:

is thier a easier script i can learn so i have an understanding of scripting then come back to this and have it easier? i got to the house and i give up.

Exercism isn’t intended for total beginners so anything you do here will be hard.
Scripting isn’t any different from most programming - you’re learning the same fundamental things, so choosing any popular language is good. JavaScript is probably the most logical choice, but anything with good beginner courses is good.

7rss1x

Oh, darn. I wasn’t supposed to say anything about the offices and free lunches. Please disregard!!