Element can not be retrieved from a list that matches elements from another list

I need Conversation Items from the list with the same users as list c,
The problem is that I can not move it because there is a return policy for the first article all the time conversationsList


 public class UnitTest1
    {
        private readonly ITestOutputHelper output;

        public UnitTest1(ITestOutputHelper output)
        {
            this.output = output;
        }

        (Fact)
        public void Test1()
        {
            var user1 = new User()
            {
                Id = System.Guid.NewGuid(),
                Username = "user1"
            };
            var user2 = new User()
            {
                Id = System.Guid.NewGuid(),
                Username = "user2"
            };
            var user3= new User()
            {
                Id = System.Guid.NewGuid(),
                Username = "user3"
            };
            var user4 = new User()
            {
                Id = System.Guid.NewGuid(),
                Username = "user4"
            };

            var conversationsList = new List();

            var conversation1 = new Conversation()
            {
                Id = System.Guid.NewGuid(),
                User = new List()
            };
            conversation1.User.Add(user1);
            conversation1.User.Add(user2);


            var conversation2 = new Conversation()
            {
                Id = System.Guid.NewGuid(),
                User = new List()
            };
            conversation1.User.Add(user1);
            conversation1.User.Add(user3);


            var conversation3 = new Conversation()
            {
                Id = System.Guid.NewGuid(),
                User = new List()
            };
            conversation1.User.Add(user2);
            conversation1.User.Add(user3);


            output.WriteLine(conversation1.Id.ToString());
            output.WriteLine(conversation2.Id.ToString());
            output.WriteLine(conversation3.Id.ToString());


            conversationsList.Add(conversation1);
            conversationsList.Add(conversation2);
            conversationsList.Add(conversation3);

            var c  = new List();
            c.Add(user2);
            c.Add(user3);


            var q = conversationsList.Where(p => p.User.Any(i => c.Any(s => s.Username == i.Username)));


            var conversations = q.ToList();
            for (int i = 0; i < conversations.Count; i++)
            {                

                output.WriteLine(conversations(i).Id.ToString());
                output.WriteLine(conversations(i).User.ToArray()(0).Username.ToString());
                output.WriteLine(conversations(i).User.ToArray()(1).Username.ToString());


            }

        }
    }

c – Please be for tomorrow How are passwords generated for each entered name and how is a function created to display the next password to be retrieved?

The program is based on passwords that are automatically generated for each registered user, e.g. For example, answering a bank that generates a password and displays the next password to call … Follow the code below.

#include   
#include   

struct NO{  
 char dados(100);  
 int senha;  
 struct NO *prox;  
};  
typedef struct NO no;  

int tam;  

int menu(void);  
void inicia(no *FILA);  
void opcao(no *FILA, int op);  
void exibe(no *FILA);  
void exibeSenha(no *FILA);  
void libera(no *FILA);  
void adiciona(no *FILA);  
no *exclui(no *FILA);  


int main(void)  
{  
 no *FILA = (no*) malloc(sizeof(no));  
 if(!FILA){  
  printf("Sem memoria disponivel!n");  
  exit(1);  
 }else{  
 inicia(FILA);  
 int opt;  

 do{  
  opt=menu();  
  opcao(FILA,opt);  
 }while(opt);  

 free(FILA);  
 return 0;  
 }  
}  

void inicia(no *FILA)  
{  
 FILA->prox = NULL;  
 tam=0;  
}  

int menu(void)  
{  
 int opt;  

 printf("nnEscolha a opcaon");  
 printf("0. Sairn");  
 printf("1. Cadastrar novo clienten");  
 printf("2. Exibir lista de clientesn");  
 printf("3, Proxinha senha a ser chamadan");  
 printf("4. Excluir cliente/senhann");  
 printf("Opcao: "); scanf("%d", &opt);  

 return opt;  
}  

void opcao(no *FILA, int op)  
{  
 no *tmp;  
 switch(op){  
  case 0:  
   libera(FILA);  
   break;  

  case 1:  
   adiciona(FILA);  
   break;  

  case 2:  
   exibe(FILA);  
   break;  

  case 3:  
   exibeSenha(FILA);  
   break;  

  case 4:  
   tmp= exclui(FILA);  
   break;  

   default:  
   printf("Comando invalidonn");  
 }  
}  

int vazia(no *FILA)   
{  
 if(FILA->prox == NULL)  
  return 1;  
 else  
  return 0;  
}  

no *aloca()  
{  
 no *novo=(no *) malloc(sizeof(no));  
 if(!novo){  
  printf("Sem memoria disponivel!n");  
  exit(1);  
 }else{  
  printf("nNovo elemento: "); scanf("%s", &novo->dados);  
  return novo;  
 }  
}  


void exibe(no *FILA)  
{  

 if(vazia(FILA)){  
  printf("FILA vazia!nn");  
  return ;  
 }  
 no *tmp;  
 tmp = FILA->prox;     
 while( tmp != NULL){  

  printf("%s - ", tmp->dados);  
  tmp = tmp->prox;  
 }  


}  


void exibeSenha (no *FILA) {  
    if(vazia(FILA)) {  
        printf("Sem nenhuma senha cadastrada. Fila vazia!n");  
        return ;  
    }  



}  

void libera(no *FILA)  
{
 if(!vazia(FILA)){  
  no *proxNO,  
     *atual;  

  atual = FILA->prox;  
  while(atual != NULL){  
   proxNO = atual->prox;  
   free(atual);  
   atual = proxNO;  
  }  
 }  
}  

void adiciona(no *FILA)  
{  
 no *novo=aloca();  
 novo->prox = NULL;  

 if(vazia(FILA))  
  FILA->prox=novo;  
 else{  
  no *tmp = FILA->prox;  

  while(tmp->prox != NULL)  
   tmp = tmp->prox;  

  tmp->prox = novo;  
 }  
 tam++;  
}  


no *exclui(no *FILA)  
{  
 no *ultimo;  
 if(FILA->prox == NULL){  
  printf("FILA ja vaziann");  
  return NULL;  
 }else{  
  no *ultimo = FILA->prox;  
  FILA->prox=ultimo->prox;  
  free(ultimo);  

  while(ultimo->prox != NULL){  
   ultimo = ultimo->prox;  
  }  

  ultimo->prox = NULL;  
  tam--;  
  return ultimo;  
 }  
} 

Is the AWS lambda function well suited for the use case where a large amount of records are retrieved from the database at user request?

We have a use case where the lambda function is called by the API Gateway on user request from the browser, retrieves data from the database, and returns to the client. The time it takes to retrieve the data or the amount of data depends on which filters the user has selected. Do you think that the lambda function is suitable for this type of application?

Additional questions: (If the answer is yes, the Lambda function can fit well)

  • How do we estimate the memory requirements for the lambda function for such an application?
  • The lambda function (for the above use case) waits for data to be retrieved from the database. Is there a cheaper way?
    • Is a dedicated EC2 instance hosting your web app a better way?

Website Design – How can data be effectively retrieved from the onboarding process?

We currently have one very easy Onboarding process when signing up for the platform.
It consists of 3 screens:

  1. Welcome to the platform
  2. Ask for personal data (birthday, gender, place of residence, country, place of birth)
  3. Ask you to write a brief description of yourself and select soft skills from a drop-down list and professional skills from another drop-down list.

You can say that we are asking for some sensitive data, but the reason is team matchmaking. We want to group users based on their current residence and the combination of soft and hard skills. However, the onboarding process is not motivating and more aggressive.

When I read about various onboarding methods, I mainly collected information that there should be an introduction to the platform and then a kind of tutorial (in simple terms). However, I could not find any information about how users can effectively retrieve data while onboarding.

How can we make it more motivating for users to complete onboarding and not skip? Is there a logical order, which questions must be asked first and which ones last? Do you make it gamified? Maybe make chips instead of dropdowns?

sharepoint online – The client ID POSTMAN can not be retrieved

I'm trying to get the tenant ID of POSTMAN by following Access Sharepoint with POSTMAN. I took the same steps and was able to build the app. However, I can not determine the tenant ID. The answer is:

-2147024891, System.UnauthorizedAccessException
Access denied. You do not have permission to perform this action or to access this resource.

Design Pattern – When will data be retrieved / sent in an Android application?

I am currently creating an Android application and have the following questions:

We have a server that provides data for the app in the form of a REST JSON API. The app follows the MVVM architecture. Now my question is: when should we retrieve data from this server? We could retrieve all the data at once when the user reaches the first data-related screen, or we could make multiple polling calls over the lifetime of the application.

Should we also collect all data first when posting user-generated data to the server and then make a mail request or make multiple requests by sending as soon as the part data is done?

What is your opinion on this topic and can you give me guidelines on this topic?

server-side scripting – If the content is retrieved from wget, there may be a problem if I do not know the content type in the HTTP response.

The content-type is used by browsers to find out how the content is displayed. Browsers must choose the presentation method based on the content type. Rendering simple text is very different from rendering HTML.

wget Performs the same action on all files: they are stored on the hard disk. In my experience, it does not pay attention to the Content-Type Header, it only saves the file. Most file systems have no other mechanism to store metadata about the file than the file name and permissions. The content type is not even saved.

The only exception could be Mac OS. Mac's file systems can store far more metadata about files than other file system references. I have never used wget on the Mac, but it is possible that the content type will be saved there as a file metadata. This would then affect which program opens the file with the default action.

Of course, other file systems will usually guess based on the file extension .html, Since this is also wrong, the systems may behave the same way as the application types selected to open the saved file.

If you use the UUID with a specific script or application, it probably does not matter to you what the operating system would choose as the default editor and viewer for the file. I can not imagine that your use case on Windows, Mac or Linux will cause unforeseen problems.

magento2 – Wishlist Products not retrieved from the user ID: Magento 2

Wishlist added products do not getI am logged in as a user and have added some products to my wish list. It returns a blank array in the API response, but the Web adds the products to the wish list. Please check my code below

   public function __construct(
        MagentoWishlistModelWishlistFactory $wishlistFactory,
             .....................................
     ) {
        $this->wishlistFactory = $wishlistFactory;  
        .....................................
     }  

  public function getWishlist($customerId)
     {
            try {
                $wishlist = $this->wishlistFactory->create()->loadByCustomerId($customerId, true);
            } catch (NoSuchEntityException $e) {
                throw new NoSuchEntityException(__($e->getMessage()));
            }
            $wishlistItems = $wishlist->getItemCollection();
            $items = ();
            foreach ($wishlistItems as $wishlistItem) {
                $product = $this->productRepository->getById($wishlistItem->getProductId());
                $items() = (
                    'item_id' => $wishlistItem->getId(),
                    'store_id' => $wishlistItem->getStoreId(),
                    'added_at' => $wishlistItem->getAddedAt(),
                    'description' => $wishlistItem->getDescription(),
                    'qty' => $wishlistItem->getQty(),
                    'product' => $product
                );
            }
      }

Many thanks

magento2 – Magento 2.3 The offer data can not be retrieved

I'm just trying to get it Quote data but it returns like that …

array(4) 
{

    ("is_checkout_cart")=>
    bool(true)
    ("store_id")=>
    int(1)
    ("remote_ip")=>
    string(15) "106.201.234.169"
    ("x_forwarded_for")=>
    NULL
}

Here is my code

scopeConfig = $context->getScopeConfig();
        $this->session=$session;
        $this->priceHelper=$priceHelper;
    }
    public function getCheckoutData(){
        $data_array=array();
        $checkout_data=$this->session->getQuote();
        var_dump($checkout_data->getData());exit;

    }
}

Does anyone have an idea what's wrong with my code?

server-side scripting – If the content is retrieved from wget, there may be a problem if the HTTP response does not specify the correct content type.

It's a question too wget, I have a simple file uuid.html in the document root, which contains a single line 54da5638-099d-4cf3-9319-c436fcb81334, I get the line in a shell script content=$(wget localhost/uuid.txt -O -), My server, Apache, assigns the content type automatically text/html to the output document in the response returned to wget. Is it reliable to consider that wget completely ignores the content type in the response header to determine what is returned and assigned? $content? I know that Apache would set the content type to text/plain in the response header, if I used another extension for the file. That's not the question. Does the content type need to be specified in the HTTP response header? is a similar question, but the context is different: you think the request is being made by a browser. Of course I also checked if it works on my server. The question is, is this reliable regardless of the environment?