teaching machines

CS 148 Lab 3 – Math and String

September 17, 2019 by . Filed under cs1, cs148, fall 2019, labs.

Welcome to lab 3!

If you have checkpoints from the last lab to show your instructor or TA, do so immediately. No credit will be given if you have not already completed the work, nor will credit be given after the first 10 minutes of this lab.

Work with a partner that you have not worked with before.

Our goal today is to acquaint ourselves with methods of the Math and String classes.

Checkpoint 1

Person A types. Make a labs.lab03 package in your IntelliJ project.

Complete three of the following problems:

Checkpoint 2

Person B types.

Write a class Crossworder that gets two words as input and prints one vertically and one horizontally so that they intersect. For example:

vertical: coffee
horizontal: suffering
  c
  o
suffering
  f
  e
  e

This problem is very open-ended. Solve it in a way that makes sense to you.