#include "mainwindow.h"
#include "ui_mainwindow.h"
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
{
ui->setupUi(this);
}
MainWindow::~MainWindow()
delete ui;
void MainWindow::on_cal_clicked()
int a = ui->num1->value();
int b = ui->num2->value();
ui->answer->setText(QString::number(a+b));