Help me in solving PRACREARR1 problem

My issue

include <bits/stdc++.h>
using namespace std;
int main() {
cout << sum;
cin >> a >> b;
int a, b;
int sum = a + b;
return 0;
}

Learning course: Practice C++
Problem Link: Rearrange Code Practice Problem in C++

  • include <bits/stdc++.h>

  • using namespace std;

  • int main() {

  • int a, b;

  • cin >> a >> b;

  • int sum = a + b;

  • cout << sum;

  • return 0;

  • }

Your code is a simple C++ program that reads two integers from the user, calculates their sum, and prints the result