an existing entry can be removed from dictionary using the pop(method or the del operator the given key must exist in the dictionarystates pop'aldel states['vt'the in and not in operators can be used to determine if dictionary contains given key these can also be used with stringstuplesand lists if abbv not in states printabbv"is not valid state abbreviationif in gradelist print"student received at least one perfect score text files data files stored on secondary device such as hard drive or usb stick can be used for the input of data into program and the output of data from program for exampleif we want to produce and print reportwe need we need to write the information to file and then print the file the data needed to produce that report may itself be stored in file on disk we would have to extract the data from the fileprocess itand then produce the report in most languagesfiles are treated as / streams (input/output streamsin which data flows into or out of program internallystandard inputin which data is extracted from the keyboardis treated as an input stream and standard outputin which data is written to the terminalis treated as an output stream there are two main types of data files that can be used with pythontext files and binary files text file contains sequence of characters from the printable range of the ascii code this typically includes the ascii values in the range [ and ascii values and which are used for newlines and tabs examples of text files include those created by any text editor such as the source files containing your python programs binary file contains sequence of binary numbers representing data values as they would be stored in memory examples of binary files include those created by word processorsspreadsheet applicationsand databases binary files cannot be read and displayed by text editors since they contain byte values outside the printable range in this sectionwe limit our discussion to text files since they are very common and easy to work with file access files are built-in type in python that are represented by objects this means no additional modules are required in order to access file from within your program before file can be usedit must first be opened and an object created to represent the file text file is opened using the open(functioninfile open"records txt""routfile open"report txt""