using System.Collections.Generic;
public static void Main()
var mpKey = "|Amazon.com";
var mpInfo = mpKey.Split('|');
var directMarketPlaceSellerId = FindDirectMarketPlaceSellerID(primarySellerId, mpInfo[1]);
if (directMarketPlaceSellerId != null) {
Console.WriteLine(directMarketPlaceSellerId);
public static int? FindDirectMarketPlaceSellerID(int primarySellerId, string marketPlaceSellerName) {
if (DirectMarketPlaceSellerIdentifiers.Any(x => {return x.Equals(marketPlaceSellerName, StringComparison.InvariantCultureIgnoreCase);})) {
private static readonly List<string> DirectMarketPlaceSellerIdentifiers = new List<string>()