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 com.levent; | |
import java.net.URL; | |
import java.net.URLClassLoader; | |
public class DelegationClasses { | |
public static void main(String[] args) { | |
URLClassLoader classLoader = (URLClassLoader) ClassLoader.getSystemClassLoader(); | |
do{ |
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 com.levo.abstractfactory.example; | |
import java.io.ByteArrayInputStream; | |
import java.io.IOException; | |
import javax.xml.parsers.DocumentBuilder; | |
import javax.xml.parsers.DocumentBuilderFactory; | |
import javax.xml.parsers.ParserConfigurationException; | |
import org.w3c.dom.Document; |
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.FileNotFoundException; | |
import java.io.PrintWriter; | |
public class GenerateDummyCode { | |
public static void main(String[] args) { | |
String className = "Eben"; | |
String newLine = "\n"; | |
String tab = "\t"; | |
String classStart = "public class " + className + " {"; | |
String closeBracket = "}"; |
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> | |
// function declarations | |
void printInteger(int *, char[]); | |
void printIntegerValue(int, char[]); | |
void printOneString(char[], char[]); | |
// implementations | |
void printInteger(int *number, char printFormat[]) | |
{ |
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> | |
// function declarations | |
void printInteger(int *); | |
void printIntegerValue(int); | |
void printOneString(char []); | |
char printFormat1[] = "Deger: %x\n"; | |
char printFormat2[] = "Deger: %s\n"; |
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
/* cl: cl /nologo /W4 bpdb_class.cpp */ | |
/* gcc: g++ bpdb_class.cpp -Wall -Wextra -pedantic -std=c++11 -o bpdb_class */ | |
#include <stdio.h> | |
#define OPEN 1 | |
#define CLOSED 0 | |
class Connection | |
{ | |
private: |
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
/* cl: cl /nologo /W4 bpdb.cpp */ | |
/* gcc: g++ bpdb.cpp -Wall -Wextra -pedantic -std=c++11 -o bpdb */ | |
#include <stdio.h> | |
#define OPEN 1 | |
#define CLOSED 0 | |
struct Connection | |
{ | |
private: |
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
/* cl: cl /nologo /W4 bpdb.c */ | |
/* gcc: gcc bpdb.c -Wall -Wextra -pedantic -std=c11 -o bpdb */ | |
#include <stdio.h> | |
#define OPEN 1 | |
#define CLOSED 0 | |
typedef struct | |
{ | |
int SomeState; |
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 <stdlib.h> | |
#define MAX_STUDENT 10 | |
#define MAX_GRADE 100 | |
int main(void) | |
{ | |
int arr[MAX_STUDENT]; | |
int option = -1; /* initial value */ |
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 <stdlib.h> | |
int main() | |
{ | |
char * numbers = "12 0x123 101"; | |
printf("\n%s %s", "before :", numbers); | |
// first token transformed | |
int first = strtol(numbers, &numbers, 10); |