 Any bug that could lead to implementation-dependent behavior in a safe language will either be detected at compile time or lead to a well-defined error behavior at run-runtime.In Java, if accessing an array out of bounds, an exception will be thrown.Examples of other safe languages are C#, Haskell and Scala.