1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
DIA [1.3K]
3 years ago
12

The datatype returned by the JOptionPane.showInputDialog method is

Computers and Technology
1 answer:
4vir4ik [10]3 years ago
5 0

Answer:

String

Explanation:

JOptionPane is a convenience swing class which displays different kinds of dialog boxes.Input dialog in particular represents prompts the user for some input. There are several polymorphic forms for this function with the most basic form being:

public static String showInputDialog(Object prompt)

As we can see the return type for this function is of type String which captures the value entered by the user on the dialog box.

You might be interested in
Disadvantage do you think one can have if he or she does use electronic media
Dima020 [189]
- discontinuity
- dependence on the electric power
and more
6 0
3 years ago
This is not school related in anyway but. I used to play this videogame on my computer years ago, but i cannot remember the name
Taya2010 [7]
Cat Quest possibly? How long ago? i remember playing many. I LOVE CATS.
4 0
3 years ago
Read 2 more answers
QUESTION 7
marishachu [46]
False, it needs to be properly cited because that is plagiarism which is illegal
6 0
3 years ago
Design a kernel module that iterates through all task in the system using the for_each_process() macro. In particular, output th
aleksley [76]

Answer:

#include <linux/kernel.h>

#include <linux/module.h>

#include <linux/init.h>

#include <linux/sched/signal.h>

#include <linux/sched.h>

 

 

struct task_struct *task;        /*    Structure defined in sched.h for tasks/processes    */

struct task_struct *task_child;        /*    Structure needed to iterate through task children    */

struct list_head *list;            /*    Structure needed to iterate through the list in each task->children struct    */

 

int iterate_init(void)                    /*    Init Module    */

{

   printk(KERN_INFO "%s","LOADING MODULE\n");    /*    good practice to log when loading/removing modules    */

     

   for_each_process( task ){            /*    for_each_process() MACRO for iterating through each task in the os located in linux\sched\signal.h    */

       printk(KERN_INFO "\nPARENT PID: %d PROCESS: %s STATE: %ld",task->pid, task->comm, task->state);/*    log parent id/executable name/state    */

       list_for_each(list, &task->children){                        /*    list_for_each MACRO to iterate through task->children    */

 

           task_child = list_entry( list, struct task_struct, sibling );    /*    using list_entry to declare all vars in task_child struct    */

     

           printk(KERN_INFO "\nCHILD OF %s[%d] PID: %d PROCESS: %s STATE: %ld",task->comm, task->pid, /*    log child of and child pid/name/state    */

               task_child->pid, task_child->comm, task_child->state);

       }

       printk("-----------------------------------------------------");    /*for aesthetics*/

   }    

     

 

   return 0;

 

}                /*    End of Init Module    */

     

void cleanup_exit(void)        /*    Exit Module    */

{

 

 

   printk(KERN_INFO "%s","REMOVING MODULE\n");

 

}                /*    End of Exit Module    */

 

module_init(iterate_init);    /*    Load Module MACRO    */

module_exit(cleanup_exit);    /*    Remove Module MACRO    */

 

MODULE_LICENSE("GPL");

MODULE_DESCRIPTION("ITERAT

5 0
3 years ago
Write a program whose input is two integers and whose output is the two integers swapped.
Tpy6a [65]

Answer:

The program to this question can be given as:

Program:

#include <iostream>  //header file

using namespace std;   //using namespace.

void SwapValues(int* userVal1, int* userVal2); //function declaration.

void SwapValues(int* userVal1, int* userVal2) //function definition.

{ //function body.

//perform swapping

   int t = *userVal1;  

   *userVal1 = *userVal2;

   *userVal2 = t;

}

int main() //main method  

{

int n1, n2; //define variable

cout<<"Enter first number :"; //message

cin>>n1; //input by user.

cout<<"Enter second number :"; //message  

cin>>n2; //input by user.

SwapValues(&n1,&n2); //calling function.

cout<<"Swapped values"<<endl;

cout<<"first number is :"<<n1<<endl; //print value

cout<<"second number is:"<<n2<<endl; //print value

return 0;

}

Output:

Enter first number :3

Enter second number :8

Swapped values

first number is :8

second number is :3

Explanation:

The description of the above C++ language program can be given as:

  • In the program, firstly we include the header file. Then we declare and define a function that is "SwapValues()" function in the function we pass two integer variable that is "userVal1 and userVal2" inside a function, we define an integer variable that is "t" and perform swapping.  
  • Then we define the main function in the main function we define two variables that is "n1 and n2" this variable is used to take value-form user. then we pass this value to function and print the function values.

5 0
3 years ago
Other questions:
  • Let's say that you handle the IT systems administration for your company. There's a server inside of your organization that chec
    14·1 answer
  • What is the full meaning of ICT
    14·2 answers
  • Choose one of the four quotes below to reflect upon. Explain what you believe the quote means about journalism. Do you agree wit
    11·1 answer
  • What's the minimum number of ip addresses that a router must have?
    6·1 answer
  • Anna's computer has slowed down. How might she improve her computer's performance?
    6·1 answer
  • Fred has to write a report on the general opinion of the influence of television on political decision-making. What internet res
    7·2 answers
  • Which type of memory helps in reading as well as writing data?
    13·1 answer
  • What does the word “Gacha” come from??????
    5·2 answers
  • Which part of the operating system enables you to interact with the device? Question 9 options: The graphical user interface The
    8·1 answer
  • Which feature helps an edit-test-bug cycle work faster in the python programming language
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!