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
natita [175]
3 years ago
12

Ethan is coding in Python and trying to add a set of numbers including both floats and integers. What should he do to make sure

he doesn't lose the information after the decimal point?
A. Stereotype

B. type cast

C. regiment

D. variable set
Computers and Technology
1 answer:
9966 [12]3 years ago
5 0

Answer:

B. type cast

///

You might be interested in
Which device protects computer systems from voltage fluctuations?
meriva
A fuse protects computer system from voltage fluctuations
6 0
3 years ago
Read 2 more answers
Allocate 100 integers and assign the resulting pointers to the elements of ip_arr. Initialize each integer value to -1.
dmitriy555 [2]

Answer:

#include <iostream>

using namespace std;

int main() {

   int *ip_arr,n;//pointer name inp_arr and integer n to store the size.

   cin>>n;//size.

   for(int  i=0;i<n;i++)

   ip_arr[i]=-1;//assigning -1 to every element.

  for(int i=0;i<n;i++)

  {

       cout<<ip_arr[i]<<" ";//printing every element.

  }

return 0;

}

output:-

100

-1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1  

Explanation:

I am taking input of size.You should enter 100 for 100 values which have value -1.

5 0
3 years ago
A string that contains only 0s,1s, and 2s is called a ternary string. How many strings of 10 ternary digits (0, 1, or 2) are the
alexdok [17]

Answer:

Number of strings = (10, 2)×(8,3) = 2520

Explanation:

The number of possible combinations for taking two 0's is C(10, 2)

It remains 8 Positions

The number of possible combinations for taking three 1's is C(8,3)

So there remains 5 spots

8 0
3 years ago
Read 2 more answers
Write a java program called allDigitsOdd that returns whether every digit of a positive integer is odd. Return true if the numbe
Vlada [557]

Answer:

public class Digits

{

   public static boolean allDigitsOdd(int num)

   {

       boolean flag=true;

       int rem;

       while(num>0)

       {

           rem=num%10;

           num=num/10;

           if(rem%2==0)    // if a even digit found immediately breaks out of loop

           {

               flag=false;

               break;

           }

       }

       return flag;     //returns result

   }

   public static void main(String args[])

   {

       System.out.println(allDigitsOdd(1375));    //returns true as all are odd digits

   }

}

OUTPUT :

true

Explanation:

Above program has 2 static methods inside a class Digits. Logic behind above function is that a number is divided by 10 until it is less than 0. Each time its remainder by 0 is checked if even immediately breaks out of the loop.

4 0
3 years ago
) What does sampling mean?
lubasha [3.4K]
In terms of music taking one song and incorporating it into your own song
6 0
3 years ago
Other questions:
  • Why are variables useful in programming?
    12·2 answers
  • All of the following are qualities of an aprenticeship except
    12·1 answer
  • In your opinion, is it more beneficial to have many folders or is it better to “nest” subfolders? Explain your response.
    10·2 answers
  • Write a class called Line that represents a line segment between two Points. Your Line objects should have the following methods
    8·1 answer
  • This assignment requires you to write a program to analyze a web page HTML file. Your program will read one character at a time
    13·1 answer
  • The _______ of a secondary storage device indicates how much data the storage medium can hold.
    13·1 answer
  • When creating an electronic slide presentation, Lee should avoid
    8·1 answer
  • Priortization is an example of a skill that helps you reach long term goals because
    14·1 answer
  • Table Setting in any occasion can add to the beauty and significance of the event. It may
    6·1 answer
  • Koi jinda hei kya hello​
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!