Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Jeffrey A. Hoffer Fred R. McFadden

4th Edition

0805360476, 978-0805360479

Students also viewed these Databases questions