/Programming-with-Google-Go

This repo has all the code develop in the course "Programming with Google Go" from coursera course By University of California, Irvine

Primary LanguageGo

#README This repository contains solutions to exercises from an online course about the Go programming language.

##Contents The repository contains the following exercise solutions:

  • Exercise 1: A program that prompts the user to enter a float number, truncates it to an integer, and prints the truncated number to the console.

  • Exercise 2: A program that prompts the user to enter a string, searches the entered string for the characters 'i', 'a', and 'n', and prints either "Found!" or "Not Found!" depending on the search results.

  • Exercise 3: A program that calculates the area of a rectangle, based on user input of the length and width of the rectangle.

-Exercise 4: A program that asks the user to enter their name and address, creates a map with the entered data, creates a JSON object from the map using the Marshall() function, and prints the JSON object to the console.

###How to use

  • Download or clone the repository to your computer.
  • Open the file for the exercise you are interested in with a Go compiler or text editor.
  • Run the program by typing go run .go in your terminal.
  • Follow the instructions provided by the program to input any necessary data.
  • The program will run and output the result to the console.

**Note: Please ensure that you have Go installed on your computer before attempting to run any of the programs in this repository.