How can I make this console prime number calculator code shorter?(C#)

I want to make my calculator code shorter.

It is my code:

using System;

namespace ConsolePrimeNumberCalculator1
{
    class Program
    {
        static void Main(string() args)
        {
            Console.Title = "ConsolePrimeNumberCalculator1";
            do
            {
                double a = 0;
                double b = 0;
                double c = 0;
                double d = 0;
                double e = 0;
                a = Convert.ToDouble(Console.ReadLine());
                if (a % 1 == 0)
                {
                    if (a > 1)
                    {
                        for (b = 2; b <= a; b++)
                        {
                            d = 2;
                            c = 1;
                            while (d < b)
                            {
                                if (b % d == 0)
                                {
                                    c = 0;
                                    break;
                                }
                                d++;
                            }
                            if (c == 1)
                            {
                                e = 1 + e;
                            }
                            if (a > 50000)
                            {
                                Console.WriteLine("Number is Big");
                                break;
                            }
                        }
                        if (a < 50001)
                        {
                            Console.WriteLine(e);
                        }
                    }
                    else
                    {
                        Console.WriteLine("Number is Small");
                    }
                }
                else
                {
                    if (a > 1)
                    {
                        Console.WriteLine("Number is not Integer");
                    }
                    else
                    {
                        Console.WriteLine("Number is not Integer");
                        Console.WriteLine("Number is Small");
                    }
                }
            }
            while (true);
        }
    }
}

Can I make this code shorter? Is it possible to do? If it is, how?

svn – Change Console and repo browser certificate for Collabnet svnedge

I need to change ssl certificate for our collabnet svn edge console and repo browser. I came across few documentations for changing ssl on console by creating new svnedge.jks file and replacing it with old one in csvn/appserver/etc/ directory, but whenever I do it svn edge consoled doesn’t start. It gives below error

“WARNING: CSVN Console timed-out waiting for http://localhost:3343/csvn”

I will index your WordPress website on google, bing search console setup robots. txt and webmasters for $120

I will index your WordPress website on google, bing search console setup robots. txt and webmasters

About This Gig!


Are you looking for an anOn-Page SEO Expert?

I am an efficient SEO expert and can index your WordPress and set up Google Analytics and
Search Console (Webmaster Tools) + Install Sitemap (XML) For Your Website.

What Will You Get From me?
· Webmaster Tool andGoogle Analytics Setup and Configuration

· Configure, Submit an XML sitemap

· Creation andOptimization Of Robort.txt

· Site submission onGoogle and Bing Search Console

· H1, H2, H3 Tags Setup

· SEO audit report

· keyword research

· Optimized Title &Meta Description

· Increasing organic traffic

· Yoast best setting

Why You Select Me?

· On-time Delivery

· Money-back Guarantee

· SEO Expert

· 100% Satisfaction

If you have any questions, please do not forget to contact me. Client satisfaction is my priority!

.(tagsToTranslate)on-page(t)wordpress(t)webmaster(t)robot.txt(t)Keyword-research(t)site

lua – Why can’t I access LocalPlayer at runtime in a starterGui script, but I can in the console at runtime?

In

StartGui -> ScreenGui -> TextLabel -> Banner (a script)

I’ve got

local ever = false
while (not ever) do
 wait(1)
    local player = game:GetService("Players").LocalPlayer
    print(player)
end

When I Play, I see nil every second in the console. But if I type = game:GetService("Players").LocalPlayer into the console, I see the name of my character.

What subtle thing am I missing?

c++ – Printing rdbuf() to console works, but getline fails

I’m having a strange issue where printing to the console using rdbuf() from a file using ifstream works, but the string parameter inside of getline never returns a value, and thus fails to print to the console in a for loop. I was trying to add the lines in the file to a vector for processing and I know there’s other methods to do that, but I’m confused as to why the getline would fail. The file consists of the following text:

One
Two
Three
Four

Code below.

    std::string path = "C:/testfile.txt";      

    std::ifstream File(path);
    File.open(path);
    std::string placeholder;

    if (!File.is_open())
    {
        std::cout << "WARNING: Unable to open file" << std::endl;
    }
    else
    {
        //This prints to the console correctly;
        std::filebuf* stream = File.rdbuf();
        std::cout << stream << std::endl;
        //------------------------------------

        //This fails because placeholder is always "" and the loop doesn't run.
        for (std::string output; std::getline(File, placeholder);) 
        {
            std::cout << output << std::endl;
        }

        File.close();
    }

cors – WordPress: console errors from web sites I have linked to

On this one page of my site, https://litchfieldmagazine.com/litchfield-county-design-resource-guide/

I have hundreds of console errors that are coming from sites I have linked to in the posts displayed on the page. Security errors, iframe warning, font warnings etc.

I know what to do if these were errors on my site, but why am I getting errors about content that is not even on my site, but is on someone else’s that I have just hyperlinked to?

I have never seen anything like this before.

amazon web services – Cannot sign in to aws console

I’m having problems getting to the signin page of aws in Ubuntu 20.04 with latest updates. As I suspect this to be a network problem, I’ve tried accessing with curl and openssl. Sometimes (randomly) following commands doesn’t fail and I get successful responses, but most of the time I’m getting following responses:

~ curl -vvv https://signin.aws.amazon.com
*   Trying 176.32.98.146:443...
* TCP_NODELAY set
* Connected to signin.aws.amazon.com (176.32.98.146) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to signin.aws.amazon.com:443 
* Closing connection 0
curl: (35) OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to signin.aws.amazon.com:443
openssl s_client -connect signin.aws.amazon.com:443 
CONNECTED(00000003)
write:errno=0
---
no peer certificate available
---
No client certificate CA names sent
---
SSL handshake has read 0 bytes and written 313 bytes
Verification: OK
---
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
---

Some observations:

  • signing.aws.amazon.com resolves to different ip addresses and I’ve checked I’m getting both successful and error responses from same ip addresses.
  • When I get a successful response, usually next few calls are also successful if I keep trying.
  • If I connect to a VPN, these calls never fail
  • I have two ubuntu machines at home both of the have the same problem. I’ve installed curl to a windows machine and it never had the problem.
  • Successful sessions are using TLSv1.2 as expected
  • I have a very stable 100 Mbit connection with very low ping times and this problem doesn’t happen with any other domain
  • Both commands fail after 23 seconds. However when they’re successful, it takes ~400ms.
  • I tried to replace my router, but got the same results.
  • My ISP changed my IP address, but that didn’t help. As the calls are sometimes working I don’t think it’s a black-listing problem.
  • I cannot connect to site with browsers or other cli tools neither.

What else can I try to find the cause of this issue?

MacBook Pro 15 slow after reset, Console full with errors

Over the last two weeks, my MacBook decided to stop loading pages with the error “server cannot be contacted”. As it has been some time, I finally decided to reset the whole thing. It is a complete fresh install.

However, again, it is incredible slow, laggy, network is sometimes not working, animations are lagging and stuttering, I am really annoyed. I did a Diagnosis with the diagnosis utilities before resetting but it showed no problems.
I had a look into the console and there are so many errors going on, I do not even know where to start. Could they be the problem?

Some of the errors:

coreduet

Couldn't read values in CFPrefsPlistSource<0x7fa686c08d50> (Domain: kCFPreferencesAnyApplication, User: kCFPreferencesCurrentUser, ByHost: No, Container: (null), Contents Need Refresh: Yes): accessing preferences outside an application's container requires user-preference-read or file-read-data sandbox access

com.apple.WebKit.WebContent 

Couldn't write values for keys (NSLinguisticDataAssetsRequestTime
) in CFPrefsPlistSource<0x7fbcd6007940> (Domain: kCFPreferencesAnyApplication, User:
kCFPreferencesCurrentUser, ByHost: No, Container: (null), Contents Need Refresh: No): setting
preferences outside an application's container requires user-preference-write or
file-write-data sandbox access

Unknown class <private> in Interface Builder file at path <private>.

0 is not a valid connection ID.

flock failed to lock maps file: errno = 35

Anyone has any idea what I could/should do?

Why not just use a domain property instead of prefix properties for https, http and www in Google Search Console?

I just added my website to Google Search Console as the domain validated property example.com. Now when I try to link it with Google Analytics (GA), it says no property is added to the console.

Perhaps Google Analytics is right because I have not added any prefix property. It was just a domain name (example.com). To link my GA with GSC I have also added these prefix properties:

  • https://example.com
  • http://example.com
  • http://www.example.com
  • https://www.example.com

(all of these 4 properties redirect to my domain example.com. Why?)

I’m not able to add www.example.com as a domain property in GSC because it does not allow it

Now, after adding all 4 properties of my domain GA shows these properties when I try to link GSC with GA.

So, which property I should choose to link with GA (e.g., HTTP, HTTPS) because if I choose https://example.com as I did for my website, What about other properties. Will GA show me the data about other properties all of which land on example.com (domain).

Why add so many properties to GSC when they all land on the domain (example.com)?
Do I need to add a separate zone record (c-panel) for verification?

Why did I add so many properties when example.com (domain) seems like it should be more than enough?

Why not just example.com [domain name], besides https, http and www [protocols] in google console?

I want to ask few questions related to the Google Search Console (GSC) and Google Analytics (GA).

I just added my website to google console as example.com.

Now when I try to link my google console with Google Analytics (GA). It says no property is added to the console. Perhaps google analytic is right because I have not added any property in fact it was my domain name (example.com). To link my GA with GSC I have added these properties:

https://example.com

http://example.com

http://www.example.com

https://www.example.com

(all of these 4 properties redirect to my domain example.com. Why?)

Not able to add wwww.example.com in GSC as property because it does not allow.

Now, after adding all 4 properties of my domain GA shows these properties when I try to link GSC with GA.

So, which property I should choose to link with GA (e.g., HTTP, https) because if I choose https://example.com as I did for my website, What about other properties. Will GA show me the data about other properties all of which land on example.com (domain).

Why add so many properties to GSC when they all land on the domain (example.com)?
Do I need to add a separate zone record (c-panel) for verification?

In simple words, why to add so many properties when example.com (domain) is more than enough.

Thanks.
Best regards,