1package com.howtodoinjava;
2
3import org.apache.log4j.BasicConfigurator;
4import org.apache.log4j.Logger;
5
6public class Log4jHelloWorld {
7
8 static final Logger logger = Logger.getLogger(Log4jHelloWorld.class);
9
10 public static void main(String[] args)
11 {
12 //Configure logger
13 BasicConfigurator.configure();
14 logger.debug("Hello World!");
15 }
16}
17