Skip to main content

tool for cheating exam

Project description

codebank

A Python Package for Easy Access to Predefined Code Snippets for Exams

This package provides easy access to predefined Python code snippets that can be directly used in exams or coding assessments. By calling simple functions, users can retrieve code examples on various topics, copy the output from the console, and paste it into their compiler or editor for execution.


Features

  • Predefined code snippets for common Python problems.
  • Easy-to-use function calls.
  • Useful for exam preparation and quick reference.

Installation

To install the package, use pip:

pip install codebank

Usage

After installation, you can import the package and start retrieving predefined code snippets by calling simple functions.

Example 1: Retrieve a Function to Find Prime Numbers

import codebank

# Call the required function to retrieve the code
code_snippet = codebank.one()   

# The code will be printed in the console, and you can copy it
print(code_snippet)

Output:

import numpy as np
import pandas as pd
df=pd.read_csv('Iris1.csv')
df.head()
from sklearn import tree
from sklearn.model_selection import train_test_split
X=df[['SepalLengthCm','SepalWidthCm','PetalLengthCm','PetalWidthCm']]
Y=df['Species']
X_train,X_test,Y_train,Y_test=train_test_split(X,Y,test_size=0.2)
model=tree.DecisionTreeClassifier()
model.fit(X_train,Y_train)
print("score",model.score(X_test,Y_test))
tree.plot_tree(model)

Available Functions

  • one(): Decision Tree Classifier

  • two(): Spam Detection using Support Vector Machine

  • three(): Face Detection using Cascading

  • four(): Face Recognisation using ANN

  • five(): K Nearest Neighbour

  • fivea(): Adult Salary Prediction using Random Forest

  • six(): Multi Layer Perceptron for Character Recognisation

  • seven(): Sentiment Analysis using Random Forest

  • eight(): Bayesian Network for Heart Disease

  • nine(): Fraud Detection using ANN

  • More functions can be added to cover additional topics such as searching, recursion, data structures, etc.


How to Use

  1. Copy the Code: After calling a function, copy the printed code snippet from the console.
  2. Paste and Run: Paste it into your Python editor or compiler.
  3. Modify (Optional): If required, you can modify the function parameters or extend the code as per your needs.

Contributing

Contributions are welcome! If you would like to add more code snippets or suggest improvements, feel free to fork the repository and submit a pull request.


License

This project is licensed under the MIT License. See the LICENSE file for details.


Feedback

For issues, bugs, or feature requests, feel free to open an issue on the GitHub repository.


This README provides a simple and clear guide for users, focusing on ease of use and practical functionality for exam preparation. It walks through installation, usage examples, available functions, and contribution guidelines.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

codebank-0.2.1.tar.gz (22.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

codebank-0.2.1-py3-none-any.whl (21.9 kB view details)

Uploaded Python 3

File details

Details for the file codebank-0.2.1.tar.gz.

File metadata

  • Download URL: codebank-0.2.1.tar.gz
  • Upload date:
  • Size: 22.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.7

File hashes

Hashes for codebank-0.2.1.tar.gz
Algorithm Hash digest
SHA256 5fac705b5706c6f517ea7c38089e689bf40af2f9a0f17725066b9e04e8c46929
MD5 4c1d5f53ed44e91a1233ce25a21321fa
BLAKE2b-256 41e4da09c6576c2bd855be4590a3a9f6ea812c12175a0d252ccfad8bfa95fb7d

See more details on using hashes here.

File details

Details for the file codebank-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: codebank-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 21.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.7

File hashes

Hashes for codebank-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6b53f7913f5286c4e22cc5735033b28c569db9b204264b8b1e28b61330140864
MD5 765cc1c9a3362aa5f01d165f2b436f30
BLAKE2b-256 471ba441e94e00ec75cddd3d2f0825e8a8434ef15d0fddc1121ec6f90003ac86

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page