it depends on how many users you expect will use both apps and how often push notifications will be sent. Namespace is top-level container and hubs are created within namespace. All 3 pricing tiers (Free, Basic and Standard) have limitation on number of active devices per namespace (500 for free, 200000 for basic and 10 million for standard) and number of pushes (1 million for free, 10 millions for basic and 10 millions for standard) - additional pushes are charged with extra cost. So if you expect that overall number of your users won't exceed 200000 you may go with single namespace and create 4 hubs there: 2 for dev and prod version of basic app and 2 others for dev/prod versions of enterprise app. It will also save you from additional costs because charging is done based on number of used namespaces (currently €8.433/month for basic and €168.66/month for standard).
If you expect that number of active devices will be higher than 200000 then it worth to use 2 namespace or use 1 namespace and standard price tier (which supports 10 million active devices).
More details can be found on Notification Hubs pricing page.