008-006-001

Method Return Value: Total Points Calculation

Easy

Problem Description

method Return Value: Total Points Calculation

In this problem, you will create a program that receives three integers as arguments, calculates their sum using a method with a return statement, and displays the result to standard output.

Learning Objective: Create method that receives multiple arguments and returns calculated result

Calculate total earned points for point card. Create method that receives points from three purchases as arguments and returns total with return statement.

Input

Line 1: Points from purchase 1 (integer)
Line 2: Points from purchase 2 (integer)
Line 3: Points from purchase 3 (integer)

Output

Total points: [total]pt
```java

## Examples

### Example 1: 50+30+20=100
Input:
```java
50
30
20
```java
Output:
```java
Total points: 100pt
```java

### Example 2: Same value three times
Input:
```java
10
10
10
```java
Output:
```java
Total points: 30pt
```java

### Example 3: Including 0 (boundary)
Input:
```java
100
0
0
```java
Output:
```java
Total points: 100pt

Test Cases

※ Output examples follow programming industry standards

Input:
50
30
20
Expected Output:
Total points: 100pt
Input:
10
10
10
Expected Output:
Total points: 30pt
Input:
100
0
0
Expected Output:
Total points: 100pt
Input:
0
0
0
Expected Output:
Total points: 0pt
❌ Some tests failed
❌ エラー発生

Your Solution

Current Mode: My Code
import java.util.Scanner;

public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
// Write your code here

sc.close();
}
}
0 B / 5 MB

You have 9 free executions remaining