Giter Site home page Giter Site logo

studentgrade's Introduction

학생 성적관리 프로그램

학생 성적 파일을 불러와서 관리하는 프로그램입니다.


파일 구성

학생 id, 이름, 중간고사 성적, 기말고사 성적


기능

  • #show, #search, #SearchGrade 는 조건에 맞는 데이터를 출력해주는 명령어이다.
  • #add, #remove, # changeGrade 는 데이터를 수정해주는 명령어이다.
  • #quit 은 프로그램을 종료하는 명령어이다.
  • 종료하기 전, 파일 저장 여부를 물은 뒤 새로운 파일로 저장시켜준다.



구조차트 (structure chart)






FlowChart





프로그램 구조 및 설명

  1. 먼저, if name == ‘main’ : 부분에서부터 프로그램이 시작된다.

  2. 파일을 불러온다.(default : students.txt)

  3. 학생 id, 이름, 중간고사 성적, 기말고사 성적을 rawDict 변수에 저장한다. 기본적으로 학생 id를 key값으로 가지는 딕셔너리를 이용하여 정보를 저장하였다.

  4. 부가적인 함수를 만든다.

    • Setting() : 파일 출력시 표의 인덱스 부분과 점선모양을 출력해주는 함수이다.

    • Stu(id, sDict) : 학생의 id와 딕셔너리를 input 값으로 넣어주면 학생 id에 맞는 딕셔너리 정보를 한 줄로 예쁘게 출력해준다.

    • saveDict(rawDict) : rawDict의 정보에서 학생의 평균과 학점을 계산하여 추가해 만든 딕셔너리를 리턴해준다.

  5. While True:

    Main()

    sDict = saveDict(rawDict)

    while 문을 통해 사용자로부터 옵션을 선택받는 main 함수를 계속 실행해준다. Main 함수에는 7가지의 옵션 함수들이 존재한다. main함수의 리턴값인 rawdict를 받아 평균과 학점의 추가정보를 가공한 sDict 로 저장해준 뒤, 새롭게 저장된 딕셔너리로 main함수를 다시 실행한다.

  6. 7개의 함수인 # show, # search, # searchgrade, # changescore, # add, # remove, #quit 는 사용자의 입력에 따라 실행해준다.

studentgrade's People

Contributors

eunchaeee avatar

Watchers

James Cloos avatar  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.