Code Monkey home page Code Monkey logo

form-validation-console-application's Introduction

Form-Validation-Console-Application

A console application in C++ using Repl.it to verify user input for an account creation form. The app checks the validity of name, CNP, phone number, and email address, displaying errors if data doesn't meet the required format.

Description

This project aims to create a console application in C++ using Repl.it that verifies the data entered in a form used to create an account on an institution's website. The form includes the following fields:

  • Full Name
  • CNP (Personal Identification Number)
  • Phone Number
  • Email Address

The application will perform the following tasks:

Data Input and Validation

  1. The user will be prompted to enter the following information:

    • Full Name: The user's first name and last name (surname).
    • CNP: The user's 13-digit Personal Identification Number.
    • Phone Number: The user's 10-digit phone number.
    • Email Address: The user's email address.
  2. The application will validate each input field to ensure that:

    • The "Full Name" field contains only letters and is in the correct format.
    • The "CNP" field has exactly 13 digits and starts with a valid code (1, 2, 5, or 6).
    • The "Phone Number" field has exactly 10 digits and contains only numbers.
    • The "Email Address" is in a valid format, containing '@' and at least one '.' after '@'.

Output

  1. If the entered data passes the required validations, the application will display the correct input data, including the user's date of birth (extracted from the CNP) in the format day, month, year.

  2. If any of the input data fails the validation, the application will display an error message, specifying the validation issue for each field that didn't meet the required format.

Getting Started

To run the project code please click the link below:

Proiect integrator / Repl.it

Example screenshots:

Here are some example input data and their corresponding output from the program.

Screenshot 2022-07-04 at 19 51 16



Screenshot 2022-07-04 at 19 51 38



Screenshot 2022-07-04 at 19 51 55



Contact

If you have any questions or suggestions, feel free to reach out to me at [[email protected]].

Notes

In the code, "in-line" comments are used to explain various sections.

Author

form-validation-console-application's People

Contributors

laurapall avatar

Watchers

 avatar

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.