lying i don't know what to do one of the new it throws an exception sometimes one of throws an exception what do you do hear right you just try to realign your like what the line definitive but but the file existed note on the line doesn't exist what am i going to do sometimes you don't know what you're going to do and when you don't know what you want to do what you do did you say hey you know that exception the doctor onto me and can keep their own so throw the exception back to me and somewhere now i don't feel so bad on the scene of the first time someone gets the exception right now if i didn't get it what you throw it in a complex one exception right on the program the program to die someone comes along bt on the hands of a didn't catch the exception you stop executing but sometimes like someone gets and i like hey i know what to do with the exception of target may get something out now i guess really odd exception was with some clothing i needed you to wear you know i wear i'm sorry i'm not quite a stylish design so i don't know what the exception once i know how to deal with the exception on down with the exception i kinda keep extreme from around that but i appreciate you getting the exception to begin with and if you don't know what to do it and you just keeps rolling along its way so one more time just for just for thrown and to the people around you perfer getting pelted with him alright cell what does this actually looks like in code so let's look at a little code come on monday uh... sleepy mac mean nak so what is actually look like an coat what's gonna happen here is our little function that we just wrote over there are a method that returned a buffered reader so this is all the same code it creates a buffered reader that's not all while it's not all hit as the user for a file name it tries to create a new buffered reader without file name if it doesn't exist it says nice try punk now follow them exist and it asks again this is just find this what we wrote this in exception that we know how to deal with we don't actually use this dx portion you don't need to care about that or whatever you just say yeah i know the file didn't exist all write out a message the user and keep executing now down here don't worry about the stefan tightening the font bigger i'm going to say hey i'm going to call my open father space where passive aggressive program after a nice week leading to the following if you get a wrong and i think on that father than exists and it says please enter farming happier durable make no more comments about has impressed the effort but he called open fala passes in this prompt and what it's guaranteed to get back as an rd object that is a ballad file right because if it didn't get about by just keeps limping here until i got a valid object that you could actually correspond has accord once the file on your like ohh that's great now i need to read the file reading the files a dangerous thing to do because i'm referring to this follows not something bad will suddenly happen in the follow though way so i put this inside another one of these try catch block so not only do i have a try catch block making the for opening the file everytime i try to read the following tension close the file i need to have one of these two so this guy comes along with us a camera have a while true live and read all the lines the file kinda like marron showed me before so i'll have this variable line that i just read a line from the file if that line is null then i know i've reached the end of the file so i'm done i break out of the while loop and i will come here and close the file always remember to close your file to be good practice if the mine is not know i'm just gonna ride it out to the screen all say red-line and alright out inside little black it's just all it's clear what the beginning and ending of the line where the line that i read it and i'll just keep doing this and when i'm done and i don't get an exception i close the file and i will skip over this catch portion and just to keep excluding which means my programs done if however well i'm reading the file one of my life they were a lot of just as it exists i come over here are the exception i say hey i got this bio exception i don't know how do you know what that right or not he looks like a israel line it doesn't exist so i'm just gonna throw an exit section to someone else so what i do insight here is wolf throw a new exception and the exception you'll always throw if you don't know which exception to throw which is most the time you won't know which exception to throw is something that we call the error exception so you say hey i dont exception i don't know how to deal with that maybe someone else who was trying to access ni taught me inside a try catch block size thrown exception up to them and see if they can catch the exception and exception on the frozen error exception and eric's and a twenty-three exception it has a parameter and that is the exception object that you're throwing along you actually got some exception object past un the exception was thrown you didn't want to look inside if you want to deal with an asthmatic i don't need to look inside a deal with it all you're going to do is just continue to pass that exception object up to the person who may have called you so when you throw an exception execution would stop in the method that you're back at that point what you throw the exception the method what and annual thrown exception up to whoever called this method unless this happens to all be inside some other catch block inside here in which case will catch the exception yourself but if you're not trying to catch the exception yourself ill just get passed up and someone else catch so any questions about this year we know how to deal with the exception here we don't know how to do with the exception and if you want to actually be able to passive eric section that something that's defined in this thing called a c and utils so it's an exception that's defined in the atm_ libraries you should import atm_ dot util dot start to be able to throw one of these eric sections so this is 