[Java] Runtime: 1ms, faster than 100% || Memory usage less than 94.82%
\nclass Solution {\n    public List<String> fizzBuzz(int n) {\n        List<String> result = new ArrayList<>();\n        for (int i = 1; i <= n; i++) {\n       
```\nclass Solution {\n    public List<String> fizzBuzz(int n) {\n        List<String> result = new ArrayList<>();\n        for (int i = 1; i <= n; i++) {\n            if (i % 3 == 0 && i % 5 == 0) result.add("FizzBuzz");\n            else if (i % 3 == 0) result.add("Fizz");\n            else if (i % 5 == 0) result.add("Buzz");\n            else result.add(String.valueOf(i));\n        }\n        return result;\n    }\n}\n```\n\n![image](https://assets.leetcode.com/users/images/400c48c4-a855-472b-a352-fad320ee1690_1666690593.446253.png)\n
['Java']