Question
Please help me write this program in C# You have a program called ListFilesInDirectory. It takes one input that is a directory path. I want
Please help me write this program in C#
You have a program called ListFilesInDirectory. It takes one input that is a directory path. I want to be able to call this code like this: ListFilesInDirectory c:\some andom\path
Given the directory as an input, I want the program to print to screen all the names of all the files and directories in that directory and all its children.
You have the following pre-written code to work with:
Directory.List(string path) returns a list of file system objects that are direct children of the given path.
Each file system object has a .Type and .Name value.
.Type is either "file" or "directory".
.Name is the full path of the file or directory.
Please Help me out, explanations helps a ton too.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started