Nov-12-2022, 01:45 AM
Hi Team,
Can we use r as raw string for variable folder_path.
because user is passing folderpath via command line.
Path(r'E:\data\transport_data') I understood this line of code.
Path(r{source_path}) .......... can we use r word infront of source_path
Can we use r as raw string for variable folder_path.
because user is passing folderpath via command line.
Path(r'E:\data\transport_data') I understood this line of code.
Path(r{source_path}) .......... can we use r word infront of source_path
from pathlib import Path #1) r string in path , I understood this approach. source_path = Path(r'E:\data\transport_data') # hard code path source_path = Path(r{source_path}) print(source_path)