08 MultiThreading
08 MultiThreading
MultiThreading – Assignment
2. Write a java program to create a class called FileWatcher that can be given
several filenames that may or may not exist. The class should start a thread for
each file name. Each thread will periodically check for the existence of its file. If
the file exists, the thread will write a message to the console and then end.
3. Write a java program to create a class called FileWatcher that can be given
several filenames that may or may not exist. The class should start a thread for
each file name. Each thread will periodically check for the existence of its file. If
the file exists, the thread will write a message to the console and then end.
6. Write a program where the Producer pushes the elements into the stack and the
Consumer pops the elements from the stack. Use Synchronization.