This file contains 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
Scanner input = new Scanner(System.in); | |
int[] circle = new int[6]; | |
System.out.print("Enter circle's (x1,y1) (x2,y2) (x3,y3) coordinates ( like this ->1 2 3 4 5 6)--->"); | |
circle[0] = input.nextInt(); | |
circle[1] = input.nextInt(); | |
circle[2] = input.nextInt(); | |
circle[3] = input.nextInt(); | |
circle[4] = input.nextInt(); | |
circle[5] = input.nextInt(); |
This file contains 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
http://www.oopweb.com/Java/Documents/ThinkCSJav/Volume/chap17.htm |
This file contains 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
http://algorithms.tutorialhorizon.com/binary-search-tree-complete-implementation/ |
This file contains 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.*; | |
import java.util.stream.Collectors; | |
import java.util.stream.IntStream; | |
/** | |
* Created by yasincidem on 19.3.2018. | |
*/ | |
public class mTSP { | |
private int numDepots; | |
private int numSalesmen; |
This file contains 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
package edu.anadolu; | |
import java.util.ArrayList; | |
import java.util.Collections; | |
import java.util.List; | |
import java.util.Random; | |
import java.util.stream.Collectors; | |
/** | |
* Created by yasin_000 on 26.5.2018. |
This file contains 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 android.os.Bundle | |
import android.os.Handler | |
import android.os.Message | |
import android.view.View | |
import androidx.appcompat.app.AppCompatActivity | |
import kotlinx.android.synthetic.main.activity_main.* | |
import java.io.BufferedReader | |
import java.io.InputStreamReader | |
import java.net.URL |
This file contains 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 ThreadActivity : AppCompatActivity() { | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
setContentView(R.layout.activity_thread) | |
val thread = Thread { | |
val person = getPersonInfoById(5) | |
runOnUiThread { | |
progress_bar.visibility = View.GONE |
This file contains 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.io.File; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.net.ServerSocket; | |
import java.net.Socket; | |
import java.net.URISyntaxException; | |
import java.nio.file.Files; | |
import java.nio.file.Path; | |
import java.nio.file.Paths; |
This file contains 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.io.*; | |
import java.util.Arrays; | |
/** | |
* Created by yasin_000 on 1.5.2019. | |
*/ | |
public class Utils { | |
public static byte[] fileToBytes(File f) throws IOException{ | |
InputStream fis = new FileInputStream(f); |
This file contains 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 <stdio.h> | |
#include <sys/types.h> | |
#include <unistd.h> | |
#include <semaphore.h> | |
pthread_t Job0, Job1, Job2, Job3, Job4, Job5, Job6, Job7, Job8, Job9; | |
sem_t sem0, sem1, sem2, sem3, sem4, sem5, sem6, sem7, sem71, sem8, sem9, sem61, sem62; | |
void *job0() { | |
sem_wait(&sem0); | |
sleep(2); | |
printf("%s \n", "Job0 is done"); |
OlderNewer