This and the other “Deck” posts are a repurposing of flashcard study decks to Q&A blog posts. Google was not showing love to this content as a set of flashcards and I didn’t want to delete them entirely, I hope you find it useful.
When would you use the .ex extension for an Elixir file vs `.exs`?
.ex when you want to compile your code and
.ex when writing a script.
How would you execute a .exs file script from the command line?
Running the script above will execute the file without writing a compiled BEAM file to disk.
How would you execute a .ex file on the command line?
The above will write a compiled BEAM file to disk and you will be able to use the modules/functions you create in your Elixir environment.