lab12 is a butt

modified:   .gitignore
	new file:   Assignments/lab11_ForLoop_CalebFontenot/Menu2.html
	new file:   Assignments/lab11_ForLoop_CalebFontenot/MenuDoWhile.html
	new file:   Assignments/lab11_ForLoop_CalebFontenot/MenuFor.html
	new file:   Assignments/lab11_ForLoop_CalebFontenot/build.xml
	new file:   Assignments/lab11_ForLoop_CalebFontenot/manifest.mf
	new file:   Assignments/lab11_ForLoop_CalebFontenot/nbproject/build-impl.xml
	new file:   Assignments/lab11_ForLoop_CalebFontenot/nbproject/genfiles.properties
	new file:   Assignments/lab11_ForLoop_CalebFontenot/nbproject/project.properties
	new file:   Assignments/lab11_ForLoop_CalebFontenot/nbproject/project.xml
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/Lab11_ForLoop_CalebFontenot.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/Menu2.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/MenuDoWhile.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/MenuFor.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/TestBreak.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/TestContinue.java
	new file:   Assignments/lab11_ForLoop_CalebFontenot/src/lab11_forloop_calebfontenot/TestContinue1.java
	new file:   Assignments/lab12_CalebFontenot/build.xml
	new file:   Assignments/lab12_CalebFontenot/lab12-2-1.pdf
	new file:   Assignments/lab12_CalebFontenot/manifest.mf
	new file:   Assignments/lab12_CalebFontenot/nbproject/build-impl.xml
	new file:   Assignments/lab12_CalebFontenot/nbproject/genfiles.properties
	new file:   Assignments/lab12_CalebFontenot/nbproject/project.properties
	new file:   Assignments/lab12_CalebFontenot/nbproject/project.xml
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/ForNested1.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/Lab12_CalebFontenot.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/NestedForPatternA.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/NestedForPatternB.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/NestedWhilePatternC.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/WhileNested2.java
	new file:   Assignments/lab12_CalebFontenot/src/lab12_calebfontenot/WhileNested3.java
	new file:   ZIPs/lab11_ForLoop_CalebFontenot.zip
This commit is contained in:
2022-10-11 15:47:51 -05:00
parent 4b777cc8dd
commit 97ebbb64d4
32 changed files with 4553 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class ForNested1 {
public static void main(String[] args)
{
for (int i = 0; i < 3; ++i)
{
System.out.print("(i, j) = ");
for (int j = 0; j < 4; ++j)
{
System.out.print("(" + i + ", " + j + ") ");
}
System.out.println("");
}
}
}

View File

@@ -0,0 +1,21 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Main.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class Lab12_CalebFontenot {
/**
* @param args the command line arguments
*/
public static void main(String[] args)
{
// TODO code application logic here
}
}

View File

@@ -0,0 +1,30 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class NestedForPatternA {
public static void main(String[] args)
{
/*
String line = "";
//First for loop
for (int i = 1; i <= 6; ++i)
{
line = line + " " + i;
System.out.println(line);
}
*/
for (int i = 1; i < 7; i++) {
for (int j = 1; j < i + 1; j++) {
System.out.print(j + " ");
}
System.out.println();
}
}
}

View File

@@ -0,0 +1,30 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class NestedForPatternB {
public static void main(String[] args)
{
/*
String line = "";
//First for loop
for (int i = 1; i <= 6; ++i)
{
line = line + " " + i;
System.out.println(line);
}
*/
for (int i = 6; i > 0; i--) {
for (int j = 1; j < i + 1; j++) {
System.out.print(j + " ");
}
System.out.println();
}
}
}

View File

@@ -0,0 +1,28 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class NestedWhilePatternC {
public static void main(String[] args)
{
int int1 = 1, int2, int3;
while (int1 <= 6) {
System.out.print(int1 + ": ");
System.out.print("6 5 4 3 2 1");
int2 = 1;
while (int2 != int1) {
System.out.print("\b\b");
int2++;
}
System.out.println();
int1++;
}
}
}

View File

@@ -0,0 +1,24 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class WhileNested2 {
public static void main(String[] args)
{
int i = 0;
while (i < 3)
{
System.out.print("(i, j) = ");
for (int j = 0; j < 4; ++j)
System.out.print("(" + i + ", " + j + ") ");
System.out.println("");
++i;
}
}
}

View File

@@ -0,0 +1,22 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package lab12_calebfontenot;
/**
*
* @author caleb
*/
public class WhileNested3 {
public static void main(String[] args)
{
for (int i = 0; i < 3; ++i)
{
System.out.print("(i, j) = ");
for (int j = 0; j < 4; ++j)
System.out.print("(" + i + ", " + j + ") ");
System.out.println("");
}
}
}