def exist(self, table: str, libref: str ="<STR_LIT>") -> bool:
code  = "<STR_LIT>"<EOL>if len(libref):<EOL><INDENT>code += libref+"<STR_LIT:.>"<EOL><DEDENT>code += table+"<STR_LIT>"<EOL>code += "<STR_LIT>"<EOL>if len(libref):<EOL><INDENT>code += libref+"<STR_LIT:.>"<EOL><DEDENT>code += table+"<STR_LIT>"<EOL>code += "<STR_LIT>"<EOL>ll = self.submit(code, "<STR_LIT:text>")<EOL>l2 = ll['<STR_LIT>'].rpartition("<STR_LIT>")<EOL>l2 = l2[<NUM_LIT:2>].partition("<STR_LIT:\n>")<EOL>exists = int(l2[<NUM_LIT:0>])<EOL>return bool(exists)<EOL>
table  - the name of the SAS Data Set
libref - the libref for the Data Set, defaults to WORK, or USER if assigned

Returns True it the Data Set exists and False if it does not