//Programmer: Akinwale Owi
//Company: Dagba Computers
//Program Purpose: Pass a String to and From a Function
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package dagba.computer.sample;
/**
*
* @author Akin
*/
public class DagbaComputerSample {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
//String we will be passing
String first = “Dagba”;
//Sending and Printing the string to the function
System.out.println(“I could eat some “+ Pasta(first) + ” right about now”);
}//end of main
//Function that will be receiving the string
public static String Pasta (String first)
{
//String that holds the first string variable from the Main Function
String beforeTransform = first;
//String created in this function that adds Bacon
String afterTransform = first + ” Bacon”;
//Sending back the new String Variable
return afterTransform;
}//end of pasta
}//end of DagbaComputerSample Class
