This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<LinearLayout | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
tools:context=".MainActivity" | |
android:orientation="vertical"> | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Vector; | |
import java.util.Enumeration; | |
import java.util.ArrayList; | |
import java.util.List; | |
public class TryEnumeration { | |
public static void main(String args[]) { | |
// Enumeration accept Type T, it called Generics | |
Enumeration<String> days; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.*; | |
// Try compile with `javac` & `javac -Xlint` | |
class TryIterator { | |
public static void main(String args[]) { | |
// create an array list | |
ArrayList<String> al = new ArrayList(); | |
// add elements to the array list |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Test { | |
public static void main(String[] args) { | |
Buyer b1 = new Buyer("Miun", "Pasirlayung, Bandung"); | |
Purchase p = new Purchase(b1); | |
Car t = new Truck("Hino Dutro", 120000.0, 5000.0); | |
p.addCar(t); | |
Car s = new SuperCar("Bugati", 800000.0, 300.0); | |
p.addCar(s); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Author: Muhammad Fahmi I. | |
* Github: github.com/miun173 | |
* Year: 2018 | |
*/ | |
interface GeometriObject{ | |
double getPerimeter(); | |
double getArea(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Muhammad Fahmi | |
* 1401810160028 | |
* Contoh Penggunaan Array of Record | |
* 11/03/2018 | |
* | |
* Compile using : g++ -c arrayOfRecord.cpp && g++ -o arrayOfRecord.exe arrayOfRecord.o && arrayOfRecord.exe | |
*/ | |
#include <iostream> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Author: miun173 | |
* Doubly linked list | |
* @2019 | |
* */ | |
#include <iostream> | |
using namespace std; | |
struct Pembalap { | |
int nomor; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Java program for Kruskal's algorithm to find Minimum | |
// Spanning Tree of a given connected, undirected and | |
// weighted graph | |
import java.util.*; | |
import java.lang.*; | |
import java.io.*; | |
class Graph | |
{ | |
// A class to represent a graph edge |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require('express'); | |
const path = require('path'); | |
const mongoose = require('mongoose'); | |
const router = require('./routes'); | |
const bodyParser = require('body-parser'); | |
const { loggerMiddleware } = require('./logger') | |
const app = express(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
const int maxElmt = 10; | |
struct Queue { | |
int data[maxElmt]; | |
int head; | |
int tail; | |
}; |
OlderNewer