Walmart interview question

Calculate time complexity algorithms java programs.