How to hide logout part in C when execute in Atom?












0















Hi I am running the C file in on Atom.



This is my code:



#include <stdio.h>
#include <math.h>
int main(void)
{
int a, b, c, d;
int dollars, cents, total;
double weight;
double t = 0.00220462;
int twenty, ten, five, one;
int mingrams;
double minpounds;

printf("Enter the number of quarters: ");
scanf("%d", &a);
printf("Enter the number of dimes: ");
scanf("%d", &b);
printf("Enter the number of nickels: ");
scanf("%d", &c);
printf("Enter the number of pennies: ");
scanf("%d", &d);

total = a * 25 + b * 10 + c * 5 + d;
dollars = total / 100;
cents = total - dollars * 100;
weight = a * 5.67 * t + b * 2.268 * t + c * 5.0 * t + d * 2.5 * t;

printf("Total payment is %d dollars and %d cents.n", dollars, cents);
printf("Total weight of all the coins is %lf pounds.n", weight);

twenty = total / 2000;
ten = (total - twenty * 2000) / 1000;
five = (total - twenty * 2000 - ten * 1000) / 500;
one = (int)round((total - twenty * 2000 - ten * 1000 - five * 500) / 100.0);

printf("It is recommended to use the following payment form:n");
printf("%d twenty-dollar bills.n", twenty);
printf("%d ten-dollar bills.n", ten);
printf("%d five-dollar bills.n", five);
printf("%d one-dollar bills.n", one);

mingrams = twenty + ten + five + one;
minpounds = mingrams * t;
printf("It achieves the minimal weight of %d grams or %lf pounds.n", mingrams, minpounds);

return 0;
}


After I hit F5. I got the result here:



Last login: Sun Jan 20 21:49:05 on ttys000
Trans-MacBook-Air:~ tranchau$ /var/folders/9_/8t49c9954257tqvkh25j7x940000gn/T/payment ; exit;
Enter the number of quarters: 111
Enter the number of dimes: 111
Enter the number of nickels: 111
Enter the number of pennies: 111
Total payment is 45 dollars and 51 cents.
Total weight of all the coins is 3.777877 pounds.
It is recommended to use the following payment form:
2 twenty-dollar bills.
0 ten-dollar bills.
1 five-dollar bills.
1 one-dollar bills.
It achieves the minimal weight of 4 grams or 0.008818 pounds.
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

[Process completed]


I want to ask what is the purpose of the part:



logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.


Can we do something to hide that part?









share







New contributor




Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

























    0















    Hi I am running the C file in on Atom.



    This is my code:



    #include <stdio.h>
    #include <math.h>
    int main(void)
    {
    int a, b, c, d;
    int dollars, cents, total;
    double weight;
    double t = 0.00220462;
    int twenty, ten, five, one;
    int mingrams;
    double minpounds;

    printf("Enter the number of quarters: ");
    scanf("%d", &a);
    printf("Enter the number of dimes: ");
    scanf("%d", &b);
    printf("Enter the number of nickels: ");
    scanf("%d", &c);
    printf("Enter the number of pennies: ");
    scanf("%d", &d);

    total = a * 25 + b * 10 + c * 5 + d;
    dollars = total / 100;
    cents = total - dollars * 100;
    weight = a * 5.67 * t + b * 2.268 * t + c * 5.0 * t + d * 2.5 * t;

    printf("Total payment is %d dollars and %d cents.n", dollars, cents);
    printf("Total weight of all the coins is %lf pounds.n", weight);

    twenty = total / 2000;
    ten = (total - twenty * 2000) / 1000;
    five = (total - twenty * 2000 - ten * 1000) / 500;
    one = (int)round((total - twenty * 2000 - ten * 1000 - five * 500) / 100.0);

    printf("It is recommended to use the following payment form:n");
    printf("%d twenty-dollar bills.n", twenty);
    printf("%d ten-dollar bills.n", ten);
    printf("%d five-dollar bills.n", five);
    printf("%d one-dollar bills.n", one);

    mingrams = twenty + ten + five + one;
    minpounds = mingrams * t;
    printf("It achieves the minimal weight of %d grams or %lf pounds.n", mingrams, minpounds);

    return 0;
    }


    After I hit F5. I got the result here:



    Last login: Sun Jan 20 21:49:05 on ttys000
    Trans-MacBook-Air:~ tranchau$ /var/folders/9_/8t49c9954257tqvkh25j7x940000gn/T/payment ; exit;
    Enter the number of quarters: 111
    Enter the number of dimes: 111
    Enter the number of nickels: 111
    Enter the number of pennies: 111
    Total payment is 45 dollars and 51 cents.
    Total weight of all the coins is 3.777877 pounds.
    It is recommended to use the following payment form:
    2 twenty-dollar bills.
    0 ten-dollar bills.
    1 five-dollar bills.
    1 one-dollar bills.
    It achieves the minimal weight of 4 grams or 0.008818 pounds.
    logout
    Saving session...
    ...copying shared history...
    ...saving history...truncating history files...
    ...completed.

    [Process completed]


    I want to ask what is the purpose of the part:



    logout
    Saving session...
    ...copying shared history...
    ...saving history...truncating history files...
    ...completed.


    Can we do something to hide that part?









    share







    New contributor




    Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.























      0












      0








      0








      Hi I am running the C file in on Atom.



      This is my code:



      #include <stdio.h>
      #include <math.h>
      int main(void)
      {
      int a, b, c, d;
      int dollars, cents, total;
      double weight;
      double t = 0.00220462;
      int twenty, ten, five, one;
      int mingrams;
      double minpounds;

      printf("Enter the number of quarters: ");
      scanf("%d", &a);
      printf("Enter the number of dimes: ");
      scanf("%d", &b);
      printf("Enter the number of nickels: ");
      scanf("%d", &c);
      printf("Enter the number of pennies: ");
      scanf("%d", &d);

      total = a * 25 + b * 10 + c * 5 + d;
      dollars = total / 100;
      cents = total - dollars * 100;
      weight = a * 5.67 * t + b * 2.268 * t + c * 5.0 * t + d * 2.5 * t;

      printf("Total payment is %d dollars and %d cents.n", dollars, cents);
      printf("Total weight of all the coins is %lf pounds.n", weight);

      twenty = total / 2000;
      ten = (total - twenty * 2000) / 1000;
      five = (total - twenty * 2000 - ten * 1000) / 500;
      one = (int)round((total - twenty * 2000 - ten * 1000 - five * 500) / 100.0);

      printf("It is recommended to use the following payment form:n");
      printf("%d twenty-dollar bills.n", twenty);
      printf("%d ten-dollar bills.n", ten);
      printf("%d five-dollar bills.n", five);
      printf("%d one-dollar bills.n", one);

      mingrams = twenty + ten + five + one;
      minpounds = mingrams * t;
      printf("It achieves the minimal weight of %d grams or %lf pounds.n", mingrams, minpounds);

      return 0;
      }


      After I hit F5. I got the result here:



      Last login: Sun Jan 20 21:49:05 on ttys000
      Trans-MacBook-Air:~ tranchau$ /var/folders/9_/8t49c9954257tqvkh25j7x940000gn/T/payment ; exit;
      Enter the number of quarters: 111
      Enter the number of dimes: 111
      Enter the number of nickels: 111
      Enter the number of pennies: 111
      Total payment is 45 dollars and 51 cents.
      Total weight of all the coins is 3.777877 pounds.
      It is recommended to use the following payment form:
      2 twenty-dollar bills.
      0 ten-dollar bills.
      1 five-dollar bills.
      1 one-dollar bills.
      It achieves the minimal weight of 4 grams or 0.008818 pounds.
      logout
      Saving session...
      ...copying shared history...
      ...saving history...truncating history files...
      ...completed.

      [Process completed]


      I want to ask what is the purpose of the part:



      logout
      Saving session...
      ...copying shared history...
      ...saving history...truncating history files...
      ...completed.


      Can we do something to hide that part?









      share







      New contributor




      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.












      Hi I am running the C file in on Atom.



      This is my code:



      #include <stdio.h>
      #include <math.h>
      int main(void)
      {
      int a, b, c, d;
      int dollars, cents, total;
      double weight;
      double t = 0.00220462;
      int twenty, ten, five, one;
      int mingrams;
      double minpounds;

      printf("Enter the number of quarters: ");
      scanf("%d", &a);
      printf("Enter the number of dimes: ");
      scanf("%d", &b);
      printf("Enter the number of nickels: ");
      scanf("%d", &c);
      printf("Enter the number of pennies: ");
      scanf("%d", &d);

      total = a * 25 + b * 10 + c * 5 + d;
      dollars = total / 100;
      cents = total - dollars * 100;
      weight = a * 5.67 * t + b * 2.268 * t + c * 5.0 * t + d * 2.5 * t;

      printf("Total payment is %d dollars and %d cents.n", dollars, cents);
      printf("Total weight of all the coins is %lf pounds.n", weight);

      twenty = total / 2000;
      ten = (total - twenty * 2000) / 1000;
      five = (total - twenty * 2000 - ten * 1000) / 500;
      one = (int)round((total - twenty * 2000 - ten * 1000 - five * 500) / 100.0);

      printf("It is recommended to use the following payment form:n");
      printf("%d twenty-dollar bills.n", twenty);
      printf("%d ten-dollar bills.n", ten);
      printf("%d five-dollar bills.n", five);
      printf("%d one-dollar bills.n", one);

      mingrams = twenty + ten + five + one;
      minpounds = mingrams * t;
      printf("It achieves the minimal weight of %d grams or %lf pounds.n", mingrams, minpounds);

      return 0;
      }


      After I hit F5. I got the result here:



      Last login: Sun Jan 20 21:49:05 on ttys000
      Trans-MacBook-Air:~ tranchau$ /var/folders/9_/8t49c9954257tqvkh25j7x940000gn/T/payment ; exit;
      Enter the number of quarters: 111
      Enter the number of dimes: 111
      Enter the number of nickels: 111
      Enter the number of pennies: 111
      Total payment is 45 dollars and 51 cents.
      Total weight of all the coins is 3.777877 pounds.
      It is recommended to use the following payment form:
      2 twenty-dollar bills.
      0 ten-dollar bills.
      1 five-dollar bills.
      1 one-dollar bills.
      It achieves the minimal weight of 4 grams or 0.008818 pounds.
      logout
      Saving session...
      ...copying shared history...
      ...saving history...truncating history files...
      ...completed.

      [Process completed]


      I want to ask what is the purpose of the part:



      logout
      Saving session...
      ...copying shared history...
      ...saving history...truncating history files...
      ...completed.


      Can we do something to hide that part?







      terminal c atom atom-editor





      share







      New contributor




      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.










      share







      New contributor




      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.








      share



      share






      New contributor




      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 5 mins ago









      Nina CNina C

      1




      1




      New contributor




      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Nina C is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






















          0






          active

          oldest

          votes











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "106"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });






          Nina C is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f495694%2fhow-to-hide-logout-part-in-c-when-execute-in-atom%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          Nina C is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          Nina C is a new contributor. Be nice, and check out our Code of Conduct.













          Nina C is a new contributor. Be nice, and check out our Code of Conduct.












          Nina C is a new contributor. Be nice, and check out our Code of Conduct.
















          Thanks for contributing an answer to Unix & Linux Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f495694%2fhow-to-hide-logout-part-in-c-when-execute-in-atom%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          CARDNET

          Boot-repair Failure: Unable to locate package grub-common:i386

          Aws NAT - Aws IGW- Aws router