Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
138 changes: 138 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# Do not remove or rename entries in this file, only add new ones
# See https://github.com/flutter/flutter/issues/128635 for more context.

# Miscellaneous
*.class
*.lock
*.log
*.pyc
*.swp
.DS_Store
.atom/
.buildlog/
.history
.svn/

# IntelliJ related
*.iml
*.ipr
*.iws
.idea/

# Visual Studio Code related
.classpath
.project
.settings/
.vscode/*

# Flutter repo-specific
/bin/cache/
/bin/internal/bootstrap.bat
/bin/internal/bootstrap.sh
/bin/mingit/
/dev/benchmarks/mega_gallery/
/dev/bots/.recipe_deps
/dev/bots/android_tools/
/dev/devicelab/ABresults*.json
/dev/docs/doc/
/dev/docs/api_docs.zip
/dev/docs/flutter.docs.zip
/dev/docs/lib/
/dev/docs/pubspec.yaml
/dev/integration_tests/**/xcuserdata
/dev/integration_tests/**/Pods
/packages/flutter/coverage/
version
analysis_benchmark.json

# packages file containing multi-root paths
.packages.generated

# Flutter/Dart/Pub related
**/doc/api/
.dart_tool/
.flutter-plugins
.flutter-plugins-dependencies
**/generated_plugin_registrant.dart
.packages
.pub-preload-cache/
.pub-cache/
.pub/
build/
flutter_*.png
linked_*.ds
unlinked.ds
unlinked_spec.ds

# Android related
**/android/**/gradle-wrapper.jar
.gradle/
**/android/captures/
**/android/gradlew
**/android/gradlew.bat
**/android/local.properties
**/android/**/GeneratedPluginRegistrant.java
**/android/key.properties
*.jks

# iOS/XCode related
**/ios/**/*.mode1v3
**/ios/**/*.mode2v3
**/ios/**/*.moved-aside
**/ios/**/*.pbxuser
**/ios/**/*.perspectivev3
**/ios/**/*sync/
**/ios/**/.sconsign.dblite
**/ios/**/.tags*
**/ios/**/.vagrant/
**/ios/**/DerivedData/
**/ios/**/Icon?
**/ios/**/Pods/
**/ios/**/.symlinks/
**/ios/**/profile
**/ios/**/xcuserdata
**/ios/.generated/
**/ios/Flutter/.last_build_id
**/ios/Flutter/App.framework
**/ios/Flutter/Flutter.framework
**/ios/Flutter/Flutter.podspec
**/ios/Flutter/Generated.xcconfig
**/ios/Flutter/ephemeral
**/ios/Flutter/app.flx
**/ios/Flutter/app.zip
**/ios/Flutter/flutter_assets/
**/ios/Flutter/flutter_export_environment.sh
**/ios/ServiceDefinitions.json
**/ios/Runner/GeneratedPluginRegistrant.*

# macOS
**/Flutter/ephemeral/
**/Pods/
**/macos/Flutter/GeneratedPluginRegistrant.swift
**/macos/Flutter/ephemeral
**/xcuserdata/

# Windows
**/windows/flutter/generated_plugin_registrant.cc
**/windows/flutter/generated_plugin_registrant.h
**/windows/flutter/generated_plugins.cmake

# Linux
**/linux/flutter/generated_plugin_registrant.cc
**/linux/flutter/generated_plugin_registrant.h
**/linux/flutter/generated_plugins.cmake

# Coverage
coverage/

# Symbols
app.*.symbols

# Exceptions to above rules.
!**/ios/**/default.mode1v3
!**/ios/**/default.mode2v3
!**/ios/**/default.pbxuser
!**/ios/**/default.perspectivev3
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
!/dev/ci/**/Gemfile.lock
!.vscode/settings.json!/awesome_README.zip
8 changes: 8 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

74 changes: 74 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## 1.0.0

- Initial version.
16 changes: 13 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Quiz App
This lab will be a simple quiz app designed to test your knowledge of Git and GitHub. The app includes five functions, each representing a different aspect of Git and GitHub.

## Note:
Each function has been developed and committed separately to showcase progress. You can check each commit to see the development history and understand how each function was implemented.
This lab will be a simple quiz app designed to test your knowledge of Git and GitHub. The app includes five functions,
each representing a different aspect of Git and GitHub.

## Note:

Each function has been developed and committed separately to showcase progress. You can check each commit to see the
development history and understand how each function was implemented.

--

## Screenshot:

<img src="./screenshot/img.png" alt="result from cli">
30 changes: 30 additions & 0 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# This file configures the static analysis results for your project (errors,
# warnings, and lints).
#
# This enables the 'recommended' set of lints from `package:lints`.
# This set helps identify many issues that may lead to problems when running
# or consuming Dart code, and enforces writing Dart using a single, idiomatic
# style and format.
#
# If you want a smaller set of lints you can change this to specify
# 'package:lints/core.yaml'. These are just the most critical lints
# (the recommended set includes the core lints).
# The core lints are also what is used by pub.dev for scoring packages.

include: package:lints/recommended.yaml

# Uncomment the following section to specify additional rules.

# linter:
# rules:
# - camel_case_types

# analyzer:
# exclude:
# - path/to/excluded/files/**

# For more information about the core and recommended set of lints, see
# https://dart.dev/go/core-lints

# For additional information about configuring this file, see
# https://dart.dev/guides/language/analysis-options
14 changes: 14 additions & 0 deletions bin/functions/addition.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import '../utility/print_with_color.dart';

/*
*
* Function to add two numbers
*
* */
void addition({required double num1, required double num2}) {
// Add two numbers
final result = num1 + num2;

// Print result
printWithColor(text: "$num1 + $num2 = $result \n");
}
15 changes: 15 additions & 0 deletions bin/functions/division.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import '../utility/print_with_color.dart';

/*
*
* Function to Division tow number
*
* */
void division({required double num1, required double num2}) {
if (num2 == 0) {
printWithColor(text: 'Division by zero is not allowed', color: 'Red');
} else {
printWithColor(
text: 'The result of division is ${num1 / num2}', color: 'green');
}
}
18 changes: 18 additions & 0 deletions bin/functions/menu_display.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import '../utility/print_with_color.dart';

/*
*
* This function will display menu options
*
* */
void displayMenu() {
// Print menu options
printWithColor(text: 'CLI Calculator program', color: 'Yellow');
printWithColor(text: '1.Addition', color: 'Blue');
printWithColor(text: '2.Subtraction', color: 'Blue');
printWithColor(text: '3.Multiplication', color: 'Blue');
printWithColor(text: '4.Division', color: 'Blue');

// Print with yellow color
printWithColor(text: '5. Exit');
}
13 changes: 13 additions & 0 deletions bin/functions/multiplication.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import '../utility/print_with_color.dart';

/*
*
* Function to multiplication tow numbers
*
* */
void multiplication({required double num1, required double num2}) {
// Subtract two numbers
final result = num1 * num2;
// Print result
printWithColor(text: "$num1 - $num2 = $result \n");
}
13 changes: 13 additions & 0 deletions bin/functions/subtraction.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import '../utility/print_with_color.dart';

/*
*
* Function to subtract two numbers
*
* */
void subtraction({required double num1, required double num2}) {
// Subtract two numbers
final result = num1 - num2;
// Print result
printWithColor(text: "$num1 - $num2 = $result \n");
}
Loading