Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
tonydattolo committed Jan 17, 2020
1 parent d00cf8f commit 292d2a8
Show file tree
Hide file tree
Showing 25 changed files with 551 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,41 @@
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "CodeLens (Launch) - One",
"request": "launch",
"mainClass": "ClassProblems.Class2.One",
"projectName": "H212_e5d32889"
},
{
"type": "java",
"name": "CodeLens (Launch) - strings0",
"request": "launch",
"mainClass": "ClassProblems.Class2.strings0",
"projectName": "H212_e5d32889"
},
{
"type": "java",
"name": "CodeLens (Launch) - bigdecimal1",
"request": "launch",
"mainClass": "ClassProblems.Class2.bigdecimal1",
"projectName": "H212_e5d32889"
},
{
"type": "java",
"name": "CodeLens (Launch) - class2",
"request": "launch",
"mainClass": "ClassProblems.class2",
"projectName": "H212_e5d32889"
},
{
"type": "java",
"name": "CodeLens (Launch) - HelloWorld",
"request": "launch",
"mainClass": "PrincetonJava.HelloWorld",
"projectName": "H212_e5d32889"
},
{
"type": "java",
"name": "Debug (Launch) - Current File",
Expand Down
Empty file added BookProblems/fill.txt
Empty file.
Empty file.
29 changes: 29 additions & 0 deletions ClassProblems/Class2/One.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
package ClassProblems.Class2;
import javax.swing.JComponent;
import javax.swing.JFrame;
import java.awt.*;
/**
* strings0 are IMMUTABLE
*/
public class One extends JComponent {

public One {
this.p = new Penguin();
}
public static void main(String[] args) {
JFrame a = new JFrame("Blue pill, or red?");
a.setVisible(true);
a.setSize(500,400);

One b = new One();
// System.out.println(b);
a.add(b);
}

public void paintComponent(Graphics g){
// g.setColor(Color.YELLOW);
// g.fillOval(100, 100, 200, 200);
this.p.draw();
}

}
32 changes: 32 additions & 0 deletions ClassProblems/Class2/Penguin.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
package ClassProblems.Class2;
import java.awt.*;
/**
* penguin
*/
public class Penguin {

public Penguin(String name) {
this.name = name;
}

private String name = "Tommy Gufano";
String nickname = "The Big Sleazy";
public void talk() {
System.out.println("Howdy" + this.name + " otherwise known as, " + this.nickname);
}
public void draw(Graphics g){
// THis is Lab2
g.setColor(Color.YELLOW);
g.fillOval(100, 100, 200, 200);

}
}


// public class Penguin() {
// String name = "Tommy The Big Sleazy Gufano";
// public void talk() {
// System.out.println("Howdy" + name + " otherwise known as, " + this);
// }
// }

28 changes: 28 additions & 0 deletions ClassProblems/Class2/bigdecimal0.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package ClassProblems.Class2;
import java.math.BigDecimal;
/**
* class2
*/
public class bigdecimal0 {

public static void main(String[] args) {
BigDecimal a, b, c;

a = new BigDecimal("2");
b = new BigDecimal("3");
c = new BigDecimal("4");


System.out.println(a.add(b));
System.out.println(a.add(b.multiply(c)));
System.out.println(a.multiply(b).add(c));
System.out.println(a.add(a).multiply(b).divide(c).subtract(b));
System.out.println(a.add(b.multiply(c.divide(a.subtract(b)))));

// a.add(b);
// a.add(b.multiply(c));
// a.multiply(b).add(c); 2*3 6+3
// a.add(a).multiply(b).divide(c).subtract(b); 2+2 4*3 12/4 3-3 0
// a.add(b.multiply(c.divide(a.subtract(b))));
}
}
26 changes: 26 additions & 0 deletions ClassProblems/Class2/bigdecimal1.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package ClassProblems.Class2;

import java.math.BigDecimal;

/**
* bigdecimal1
*/
public class bigdecimal1 {

public static void main(String[] args) {
BigDecimal a,b,c;
a = new BigDecimal("10");
b = new BigDecimal("2");
c = new BigDecimal("3");

System.out.println( a.add(b) ); //10 + 2
BigDecimal result;
result = (new BigDecimal("10").add(b.multiply(c)));
System.out.println(result);
// result = (new BigDecimal("10")
// System.out.println(result);
// result = (new BigDecimal("10")
// System.out.println(result);
// result = (new BigDecimal("10")
}
}
Empty file added Homework/fill.txt
Empty file.
125 changes: 125 additions & 0 deletions LaTeX 241/LogicSymbols.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
\documentclass[10pt]{beamer}
\usepackage[orientation=landscape,
size=custom,width=32,height=18.0,scale=.75]{beamerposter}
% 設定紙張大小
\title{symbol-table}
\begin{document}

\begin{frame}
\begin{tabular}{ll}
$\leq$ & $\backslash$leq \\
$\geq$ & $\backslash$geq \\
$\neq$ & $\backslash$neq \\
$\nleq$ & $\backslash$nleq \\
$\ngeq$ & $\backslash$ngeq \\
$\cong$ & $\backslash$cong \\
$\equiv$ & $\backslash$equiv \\
$\sim$ & $\backslash$sim \\
$\approx$ & $\backslash$approx \\
$\doteqdot$ & $\backslash$doteqdot \\
$\times$ & $\backslash$times \\
$\cdot $ & $\backslash$cdot \\
$\ast $ & $\backslash$ast \\
$\div$ & $\backslash$div \\
$\pm$ & $\backslash$pm \\
$\mp$ & $\backslash$mp \\
$\bigcirc$ & $\backslash$bigcirc \\
$\oplus$ & $\backslash$oplus \\
$\otimes$ & $\backslash$otimes \\
\end{tabular}
\hspace*{1ex}
\begin{tabular}{ll}
$\propto $ & $\backslash$propto \\
$\cdots $ & $\backslash$cdots \\
$\dots $ & $\backslash$dots \\
$\because$ & $\backslash$because \\
$\therefore$ & $\backslash$therefore \\
$\forall$ & $\backslash$forall \\
$\exists$ & $\backslash$exists \\
$\in$ & $\backslash$in \\
$\subset $ & $\backslash$subset \\
$\subseteq $ & $\backslash$subseteq \\
$\varnothing $ & $\backslash$varnothing \\
$\cap $ & $\backslash$cap \\
$\cup $ & $\backslash$cup \\
$\setminus $ & $\backslash$setminus \\
$\wedge $ & $\backslash$wedge \\
$\vee $ & $\backslash$vee \\
$\Rightarrow$ & $\backslash$Rightarrow \\
$\rightarrow$ & $\backslash$rightarrow \\
$\mapsto$ & $\backslash$mapsto \\
\end{tabular}
\hspace*{1ex}
\begin{tabular}{ll}
\$ & $\backslash$\$ \\
\& & $\backslash$\& \\
\% & $\backslash$\% \\
$\backslash$ & $\backslash$backslash \\
$\sharp$ & $\backslash$sharp \\
$\partial$ & $\backslash$partial \\
$90^\circ$ & 90$^\wedge\backslash$circ \\
$\parallel$ & $\backslash$parallel \\
$\bot$ & $\backslash$bot \\
$\triangle$ & $\backslash$triangle \\
$\nabla$ & $\backslash$nabla \\
$\square$ & $\backslash$square \\
$\angle$ & $\backslash$angle \\
$\Pi$ & $\backslash$Pi \\
$\Theta$ & $\backslash$Theta \\
$\Gamma$ & $\backslash$Gamma \\
$\Delta$ & $\backslash$Delta \\
$\Omega$ & $\backslash$Omega \\
$\Sigma$ & $\backslash$Sigma \\
\end{tabular}
\hspace*{1ex}
\begin{tabular}{ll}
$\alpha$ & $\backslash$alpha \\
$\beta$ & $\backslash$beta \\
$\epsilon$ & $\backslash$epsilon \\
$\zeta$ & $\backslash$zeta \\
$\eta$ & $\backslash$eta \\
$\kappa$ & $\backslash$kappa \\
$\lambda$ & $\backslash$lambda \\
$\mu$ & $\backslash$mu \\
$\xi$ & $\backslash$xi \\
$\rho$ & $\backslash$rho \\
$\tau$ & $\backslash$tau \\
$\phi$ & $\backslash$phi \\
$\psi$ & $\backslash$psi \\
$\pi$ & $\backslash$pi \\
$\theta$ & $\backslash$theta \\
$\gamma$ & $\backslash$gamma\\
$\delta$ & $\backslash$delta \\
$\omega$ & $\backslash$omega \\
$\sigma$ & $\backslash$sigma \\
\end{tabular}
\hspace*{1ex}
\begin{tabular}{ll}
$\infty$ & $\backslash$infty \\
$f\;' $ & f$\backslash$;$\prime$\\
$\int $ & $\backslash$int \\
$\oint $ & $\backslash$oint \\
$\mathbb{Z} $ & $\backslash$mathbb\{Z\} \\
$\mathbb{R} $ & $\backslash$mathbb\{R\} \\
$\mathbb{Q} $ & $\backslash$mathbb\{Q\} \\
$\sqrt[3]{2}$ & $\backslash$sqrt[3]\{2\} \\
$\frac{2}{3}$ & $\backslash$frac\{2\}\{3\} \\
$\lceil x \rceil$ & $\backslash$lceil x $\backslash$rceil \\
$\lfloor x \rfloor$ & $\backslash$lfloor x $\backslash$rfloor \\
$\{ x \}$ & $\backslash$\{ x $\backslash$\} \\
$\widehat{p} $ & $\backslash$widehat\{p\} \\
$\overline{AB} $ & $\backslash$overline\{AB\} \\
$\overleftrightarrow{AB} $ & {\scriptsize $\backslash$overleftrightarrow\{AB\} }\\
$\overset{\LARGE\frown}{\small{AB}} $ & {\scriptsize $\backslash$overset\{$\backslash$LARGE $\backslash$frown\}\{$\backslash$small\{AB\}\}}\\
%$\overrightharp{AB} $ & {\scriptsize $\backslash$overrightharp\{AB\} }*\\
%$\overset{\large \rightharpoonup}{\small{AB}} & {\scriptsize \overset{\large \rightharpoonup}{\small{AB}}}\\
%$\overset{\LARGE \frown}{\small{AB}}$ & {\scriptsize $\backslash$overset\{$\backslash$frown\}\{AB\}}\\
$ /\!\! /$ & / $\backslash$ ! $\backslash$ ! /\\
$\overset{\large \rightharpoonup}{\small{AB}}$ & {\scriptsize
$\backslash$overset\{$\backslash$large$\backslash$rightharpoonup\}\{$\backslash$small\{AB\}\} }
\end{tabular}

\end{frame}


\end{document}
14 changes: 14 additions & 0 deletions LaTeX 241/homeworkTemplate.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
\input{settings} % add packages, settings, and declarations in settings.tex

\begin{document}

\lhead{Tony Dattolo}
\rhead{CSCI-H241 Spring '20 \\ Discrete Structures \\ Homework #1}
\cfoot{\thepage\ of \pageref{LastPage}}

\begin{enumerate}
\item \input{problem_1}
% add more problem files here
\end{enumerate}

\end{document}
Loading

0 comments on commit 292d2a8

Please sign in to comment.