Skip to content

Instantly share code, notes, and snippets.

View MasKoding's full-sized avatar

Dimas Priyandi MasKoding

View GitHub Profile
from flask import Flask
app = Flask(__name__)
@app.route('/')
def hello():
return 'Hello Flask'
if __name__ =="__main__":
app.run(debug=True)
@MasKoding
MasKoding / main.java
Last active September 20, 2021 03:56
java hello world
public class Main {
public static void main(String[] args) {
System.out.println("Hello World");
}
}
@MasKoding
MasKoding / design.puml
Created September 20, 2021 04:52
plant uml
@startuml
class User {
- name : String
- age : Integer
- address : String
.. Simple Setter ..
setName(name : String) :void
setAge(age : String) : void
@MasKoding
MasKoding / User.java
Created September 20, 2021 08:34
class of user
package org.dimas.learn;
public class User {
private String name;
private Integer age;
private String address;
public String getName() {
return name;
@MasKoding
MasKoding / Main.java
Created September 20, 2021 08:39
main class for to run application
package org.dimas.learn;
public class Main {
public static void main(String[] args) {
// write your code here
// user1 instance of user
User user1 = new User();
user1.setName("John Doe");
user1.setAge(30);
package org.dimas.learn;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.LocalTime;
import java.time.format.DateTimeFormatter;
public class LearnLocaleDate {
public static void main(String[] args) {
// show current date
<?php
namespace App\Http\Controllers;
use App\Models\Siswa;
use Illuminate\Http\Request;
class SiswaResourceController extends Controller
{
/**
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Siswa extends Model
{
use HasFactory;
@extends('siswa.layout')
@section('content')
<h3> Ini Halaman Siswa </h3>
<a class="btn btn-success" href="{{ route('siswa.create')}}">Buat Baru</a>
<table class="table table-hover table-dark">
<tr>
<th>No</th>
<th>Nama</th>
@extends('siswa.layout')
@section('content')
<div class="row">
<div class="col-lg-12 margin-tb">
<div>
<h2>Add New Student</h2>
</div>
<div>
<a class="btn btn-primary" href="{{ route('siswa.index') }}"> Back</a>