GithubHelp home page GithubHelp logo

augustinwinther / lotto-simulator Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 44 KB

Program that simulates lotteries based on real world lotteries. Written in C++.

C++ 100.00%
noob-dev lotto-simulator lotto lotto-numbers cpp learning-by-doing

lotto-simulator's Introduction

Lotto Simulator

C++ program that simulates real world lotteries. I created it just too show how immensely low chance you have of winning. I'm also using this repository for increasing my C++ skills, and learning the ways of Git and programming.

lotto-simulator's People

Contributors

augustinwinther avatar

Stargazers

 avatar

Watchers

 avatar

lotto-simulator's Issues

No validation check when typing double or a float on input

If you input a float or a double (1.2, 554.221, 3.14 etc.), when the program asks the user for an int, the program still continues without checking if the input is valid.

It basically takes the whole number, (3.14) and leaves the decimal point and decimal number(s) left behind in the input stream (3.14), which basically makes the input that comes after that, output an error since it's receiving a decimal point instead of an int.

Example/Reconstruction:

Type desired lotto and press ENTER: 1.1
Regular Lotto chosen...

Please type amount of different lotto numbers you want [0 - 10 000]: ERROR! Invalid input, please try again

TODO/FIX:

  • Make the program output an error when a number containing a decimal point is inputted

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.