const express = require("express");
const bodyParser = require("body-parser");
const app = express();
app.use(bodyParser.urlencoded({ extended: true }));
app.get("/", (req, res) => {
res.send("Hello World");
});
app.get("/api/course", (req, res) => {
res.send([1,2,3]);
});
app.get("/test/:year/:month", (req, res) => {
res.send(req.params);
});
app.post("/test2/:year/:month", (req, res) => {
res.send(req.params);
});
const port = 55555;
app.listen(port, () => {
console.log(`Server running on port ${port}`);
});