#!/usr/bin/env python
# -*- encoding: utf-8 -*-

"""
@File        :   satisfacton_analysis
@Time        :   2021/06/06 09:45
@Author      :   <NAME>
@Description :
"""


OUTPUT_PATH = '.\\data\\user_feedback'
def get_score():
    output = open(OUTPUT_PATH, 'a')
    while True:
        try:
            string = input('>>>')
            score = int(string)
            if 0 <= score <= 5:
                output.write(string + '\n')
                output.close()
                return score
            else:
                print("the range of score is between 0 and 5")
        except:
            print("invalid input")
#!/usr/bin/env python
# -*- encoding: utf-8 -*-

"""
@File        :   satisfacton_analysis
@Time        :   2021/06/06 09:45
@Author      :   <NAME>
@Description :
"""


OUTPUT_PATH = '.\\data\\user_feedback'
def get_score():
    output = open(OUTPUT_PATH, 'a')
    while True:
        try:
            string = input('>>>')
            score = int(string)
            if 0 <= score <= 5:
                output.write(string + '\n')
                output.close()
                return score
            else:
                print("the range of score is between 0 and 5")
        except:
            print("invalid input")
#!/usr/bin/env python # -*- encoding: utf-8 -*- @File        :   satisfacton_analysis @Time        :   2021/06/06 09:45 @Author      :   <NAME> @Description :