Learn practical skills, build real-world projects, and advance your career
! pip install pylint
Collecting pylint Downloading pylint-2.4.4-py3-none-any.whl (302 kB) Requirement already satisfied: colorama; sys_platform == "win32" in c:\users\user\appdata\local\programs\python\python37-32\lib\site-packages (from pylint) (0.4.3) Collecting mccabe<0.7,>=0.6 Downloading mccabe-0.6.1-py2.py3-none-any.whl (8.6 kB) Collecting isort<5,>=4.2.5 Downloading isort-4.3.21-py2.py3-none-any.whl (42 kB) Collecting astroid<2.4,>=2.3.0 Downloading astroid-2.3.3-py3-none-any.whl (205 kB) Collecting wrapt==1.11.* Downloading wrapt-1.11.2.tar.gz (27 kB) Collecting typed-ast<1.5,>=1.4.0; implementation_name == "cpython" and python_version < "3.8" Downloading typed_ast-1.4.1-cp37-cp37m-win32.whl (135 kB) Requirement already satisfied: six~=1.12 in c:\users\user\appdata\local\programs\python\python37-32\lib\site-packages (from astroid<2.4,>=2.3.0->pylint) (1.14.0) Collecting lazy-object-proxy==1.4.* Downloading lazy_object_proxy-1.4.3-cp37-cp37m-win32.whl (18 kB) Building wheels for collected packages: wrapt Building wheel for wrapt (setup.py): started Building wheel for wrapt (setup.py): finished with status 'done' Created wheel for wrapt: filename=wrapt-1.11.2-py3-none-any.whl size=19595 sha256=071d2489ca14cc2cb6db3a6e3e9b3745ce8ea6166e021ed4f491421da2e92e08 Stored in directory: c:\users\user\appdata\local\pip\cache\wheels\23\5f\62\304b411f20be41821465a82bc98baabc5e68c3cdd1eb99db71 Successfully built wrapt Installing collected packages: mccabe, isort, wrapt, typed-ast, lazy-object-proxy, astroid, pylint Successfully installed astroid-2.3.3 isort-4.3.21 lazy-object-proxy-1.4.3 mccabe-0.6.1 pylint-2.4.4 typed-ast-1.4.1 wrapt-1.11.2
%%writefile primenumber.py
import sys
x=int(sys.stdin.readline())
y=int(sys.stdin.readline())
y=y+1
lst=[]
def prime(start,end):
    for val in range(start,end):
        if val>1:
            for n in range(2,value):
                if(val %n)==0:
                    break
            else:
                lst.append(val)
    print(lst)
prime(x,y)
Overwriting primenumber.py
! pylint primenumber.py
************* Module primenumber primenumber.py:2:1: C0326: Exactly one space required around assignment x=int(sys.stdin.readline()) ^ (bad-whitespace) primenumber.py:3:1: C0326: Exactly one space required around assignment y=int(sys.stdin.readline()) ^ (bad-whitespace) primenumber.py:4:1: C0326: Exactly one space required around assignment y=y+1 ^ (bad-whitespace) primenumber.py:5:3: C0326: Exactly one space required around assignment lst=[] ^ (bad-whitespace) primenumber.py:6:15: C0326: Exactly one space required after comma def prime(start,end): ^ (bad-whitespace) primenumber.py:7:26: C0326: Exactly one space required after comma for val in range(start,end): ^ (bad-whitespace) primenumber.py:8:14: C0326: Exactly one space required around comparison if val>1: ^ (bad-whitespace) primenumber.py:9:28: C0326: Exactly one space required after comma for n in range(2,value): ^ (bad-whitespace) primenumber.py:10:26: C0326: Exactly one space required around comparison if(val %n)==0: ^^ (bad-whitespace) primenumber.py:15:7: C0326: Exactly one space required after comma prime(x,y) ^ (bad-whitespace) primenumber.py:1:0: C0114: Missing module docstring (missing-module-docstring) primenumber.py:2:0: C0103: Constant name "x" doesn't conform to UPPER_CASE naming style (invalid-name) primenumber.py:3:0: C0103: Constant name "y" doesn't conform to UPPER_CASE naming style (invalid-name) primenumber.py:4:0: C0103: Constant name "y" doesn't conform to UPPER_CASE naming style (invalid-name) primenumber.py:5:0: C0103: Constant name "lst" doesn't conform to UPPER_CASE naming style (invalid-name) primenumber.py:6:0: C0116: Missing function or method docstring (missing-function-docstring) primenumber.py:9:16: C0103: Variable name "n" doesn't conform to snake_case naming style (invalid-name) primenumber.py:9:29: E0602: Undefined variable 'value' (undefined-variable) ------------------------------------ Your code has been rated at -5.71/10